<div class="easyui-layout" fit="true">
	<div region="center" border="false" style="overflow:auto;padding:5px;background:#fff;border:1px solid #ccc;height:<?=$tinggiregion?>px;"> 
	<?php if($type == "wilayah"){?>
		<fieldset>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<table cellpadding="0" cellspacing="2" style="padding-top:0px;width:500px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Wilayah</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_wilayah : '')?>' name='nama_wilayah' style="width:300px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Provinsi</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='prov' name='kode_provinsi' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optprovinsi?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kabupaten</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='kab' name='kode_kabupaten' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optkabupaten?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kecamatan</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='kec' name='kode_kecamatan' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optkecamatan?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kelurahan</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='kel' name='kode_kelurahan' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optkelurahan?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Pos</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->kode_pos : '')?>' name='kode_pos' style="width:100px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
		</form>
		</fieldset>
	<?php }elseif($type == 'dealer'){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
			<legend>Dealer</legend>
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Dealer</td>					
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='grup_dealer' name='id_group_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optgroupdealer?>
							</select>
						</td>
					</tr>		
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_dealer : '')?>' name='nama_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='status_dealer' name='status_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optstatus?>
							</select>
						</td>
					</tr>		
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kelas Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->kelas_dealer : '')?>' name='kelas_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
				
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:40px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Telepon</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_telp : '')?>' name='no_telp' style="width:150px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Fax</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_fax : '')?>' name='no_fax' style="width:150px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Email</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->email : '')?>' name='email' style="width:300px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
			</fieldset>
			
			<fieldset>
				<legend>Alamat</legend>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kota</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_kota : '')?>' name='nama_kota' style="width:150px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<textarea name="alamat" style="width:300px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat : '')?></textarea>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kelurahan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_wilayah' name='id_wilayah' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optwilayah?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kecamatan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<!-- <span id="kec_dealer"></span> -->
							<input type='text' value='' name='kec_dealer' id="kec_dealer" disabled='disabled' style="width:150px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:40px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kabupaten</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<!-- <span id="kab_dealer"></span> -->
							<input type='text' value='' name='kab_dealer' id="kab_dealer" disabled='disabled' style="width:150px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Pos</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<!-- <span id="kd_pos"></span> -->
							<input type='text' value='' name='kd_pos' id="kd_pos" disabled='disabled' style="width:50px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Provinsi</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<!-- <span id="prov_dealer"></span> -->
							<input type='text' value='' name='prov_dealer' id="prov_dealer" disabled='disabled' style="width:150px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
			</fieldset>
			
			<fieldset>
				<legend>Legal Aspec</legend>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. NPWP</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_npwp : '')?>' name='no_npwp' style="width:150px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Di NPWP</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_tertera_npwp : '')?>' name='nama_tertera_npwp' style="width:300px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No SIUP</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_siup : '')?>' name='no_siup' style="width:150px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No SITU</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_situ : '')?>' name='no_situ' style="width:150px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:40px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status Perusahaan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='status_perusahaan' name='status_perusahaan' style="width:150px; border: 1px solid silver; padding: 1px;">
								<?=$optstatusperusahaan?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status System</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='status_system' name='status_system' style="width:150px; border: 1px solid silver; padding: 1px;">
								<?=$optsystemstatus?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<textarea name="keterangan" style="width:300px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->keterangan : '')?></textarea>
						</td>
					</tr>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "supplier"){ ?>
		<fieldset>
		<legend>Form Master Supplier</legend>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >			
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Supplier</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_supplier' name='id_group_supplier' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupsupplier?>
						</select>
					</td>
				</tr>
				<!-- <tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Supplier</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->kode_supplier : '')?>' name='kode_supplier' style="width:300px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr> -->
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Supplier</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_supplier : '')?>' name='nama_supplier' style="width:300px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Telepon</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_telp : '')?>' name='no_telp' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Fax</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_fax : '')?>' name='no_fax' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Email</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->email : '')?>' name='email' style="width:300px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat" style="width:300px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat : '')?></textarea>
					</td>
				</tr>	
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status Supplier</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='status_supplier' name='status_supplier' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optstatus?>
						</select>
					</td>
				</tr>				
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:40px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Wilayah</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_wilayah' name='id_wilayah' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optwilayah?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Provinsi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<span id="prov_dealer"></span>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kabupaten</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<span id="kab_dealer"></span>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kecamatan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<span id="kec_dealer"></span>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kelurahan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<span id="kel_dealer"></span>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Pos</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<span id="kd_pos"></span>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Akun Bank</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_akun_bank : '')?>' name='nama_akun_bank' style="width:300px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Rekening</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_akun_bank : '')?>' name='no_akun_bank' style="width:200px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. NPWP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_npwp : '')?>' name='no_npwp' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Di NPWP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_tertera_npwp : '')?>' name='nama_tertera_npwp' style="width:300px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
		</form>
		</fieldset>		
	<?php }elseif($type == "customer"){ ?>
		<fieldset>
		<legend>Form Master Customer</legend>		
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >			
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Customer</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_customer' name='id_group_customer' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupcustomer?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Customer</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->kode_customer : '')?>' name='kode_customer' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Customer</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_customer : '')?>' name='nama_customer' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tempat Lahir</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->tempat_lahir : '')?>' name='tempat_lahir' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Lahir</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select name="tanggal" style="width:85px; border: 1px solid silver; padding: 1px;">
							<?=$opttanggal?>
						</select>
						&nbsp; - &nbsp
						<select name="bulan" style="width:90px; border: 1px solid silver; padding: 1px;">
							<?=$optbulan?>
						</select>
						&nbsp; - &nbsp
						<select name="tahun" style="width:80px; border: 1px solid silver; padding: 1px;">
							<?=$opttahun?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Agama</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_agama' name='id_agama' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optagama?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Telepon</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_telp : '')?>' name='no_telp' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Ponsel</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_handphone : '')?>' name='no_handphone' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Fax</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_fax : '')?>' name='no_fax' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Email</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->email : '')?>' name='email' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama di BPKB</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_di_bpkb : '')?>' name='nama_di_bpkb' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. KTP</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_ktp : '')?>' name='no_ktp' style="width:200px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat KTP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_ktp" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_ktp : '')?></textarea>
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;margin-left:30px;width:500px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat Customer</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_customer" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_customer : '')?></textarea>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status Tempat Tinggal</td>					
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_status_tmp_tinggal_customer' name='id_status_tmp_tinggal_customer' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optststmptinggal?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Pekerjaan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_pekerjaan' name='id_pekerjaan' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optpekerjaan?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. NPWP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_npwp : '')?>' name='no_npwp' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama di NPWP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_tertera_npwp : '')?>' name='nama_tertera_npwp' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Usaha/Kantor</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_usaha : '')?>' name='nama_usaha' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat Usaha/Kantor</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_kantor" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_kantor : '')?></textarea>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Telepon Usaha/Kantor</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->tlp_kantor : '')?>' name='tlp_kantor' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Contact Person</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->contact_person : '')?>' name='contact_person' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Ponsel CP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_hp_contact_person : '')?>' name='no_hp_contact_person' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
		</form>
		</fieldset>				
	<?php }elseif($type == "gudang"){ ?>
		<fieldset>
		<legend>Form Master Gudang</legend>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >			
			<table cellpadding="0" cellspacing="2" style="padding-top:0px;width:500px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Dealer</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_dealer' name='id_group_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupdealer?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Dealer</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_dealer' name='id_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optdealer?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Divisi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_divisi' name='id_divisi' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optdivisi?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Gudang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->kode_gudang : '')?>' name='kode_gudang' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Gudang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_gudang : '')?>' name='nama_gudang' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Lokasi Gudang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_lokasi_gudang : '')?>' name='nama_lokasi_gudang' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Rak Gudang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_rak_gudang : '')?>' name='no_rak_gudang' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="keterangan" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->keterangan : '')?></textarea>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status Gudang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='status_gudang' name='status_gudang' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optstatus?>
						</select>
					</td>
				</tr>
			</table>
		</form>
		</fieldset>
	<?php }elseif($type == "karyawan"){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<fieldset>
			<legend>Identitas Karyawan</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Karyawan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_karyawan : '')?>' name='nama_karyawan' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">NIK</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nik_karyawan : '')?>' name='nik_karyawan' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jenis Kelamin</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='radio' name='jenis_kelamin' <?=$lelaki?> value='L'>&nbsp; Laki-Laki &nbsp;&nbsp;
						<input type='radio' name='jenis_kelamin' <?=$perempuan?> value='P'>&nbsp; Perempuan
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kewarganegaran</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='radio' name='kewarganegaraan' <?=$wni?> value='WNI'>&nbsp; WNI &nbsp;&nbsp;
						<input type='radio' name='kewarganegaraan' <?=$wna?> value='WNA'>&nbsp; WNA
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tempat Lahir</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->tempat_lahir : '')?>' name='tempat_lahir' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Lahir</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select name="tanggal" style="width:85px; border: 1px solid silver; padding: 1px;">
							<?=$opttanggal?>
						</select>
						&nbsp; - &nbsp
						<select name="bulan" style="width:90px; border: 1px solid silver; padding: 1px;">
							<?=$optbulan?>
						</select>
						&nbsp; - &nbsp
						<select name="tahun" style="width:80px; border: 1px solid silver; padding: 1px;">
							<?=$opttahun?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Agama</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_agama' name='id_agama' style="width:200px; border: 1px solid silver; padding: 1px;">
							<?=$optagama?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status Kawin</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='radio' name='status_kawin' <?=$M?> value='M'>&nbsp; Menikah &nbsp;&nbsp;
						<input type='radio' name='status_kawin' <?=$BM?> value='BM'>&nbsp; Belum Menikah &nbsp;&nbsp;
						<input type='radio' name='status_kawin' <?=$JD?> value='JD'>&nbsp; Janda/Duda
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Telepon</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_telp : '')?>' name='no_telp' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Ponsel</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_handphone : '')?>' name='no_handphone' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Email</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->email : '')?>' name='email' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>				
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;margin-left:30px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Foto Karyawan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px;">
						<?=$foto?> <br/>
						<input type='file' name='foto_karyawan' style="width:225px; border: 1px solid silver; padding: 1px;margin-top:2px;">
					</td>
				</tr>
			</table>
			</fieldset>
			
			<fieldset>
			<legend>Jabatan Karyawan</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Dealer</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_dealer' name='id_group_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupdealer?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Dealer</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_dealer' name='id_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optdealer?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Divisi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_divisi' name='id_divisi' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optdivisi?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Departemen</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_divisi' name='id_divisi' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=($editstatus == 'edit' ? '' : '<option value=\'\'>-- Pilih --</option>')?>
						</select>
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;margin-left:30px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jabatan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->jabatan : '')?>' name='jabatan' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tgl Masuk Kerja</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' id='tanggal_masuk_kerja' name='tanggal_masuk_kerja' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status Karyawan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_status_karyawan' name='id_status_karyawan' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optstskaryawan?>
						</select>
					</td>
				</tr>							
			</table>
			</fieldset>
			
			<fieldset>
			<legend>Pend. Karyawan</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Pend. Terakhir</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->pendidikan_terakhir : '')?>' name='pendidikan_terakhir' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jurusan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->jurusan_pendidikan : '')?>' name='jurusan_pendidikan' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Instansi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_tempat_pendidikan : '')?>' name='nama_tempat_pendidikan' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat Instansi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_tempat_pendidikan" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_tempat_pendidikan : '')?></textarea>
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;margin-left:30px;width:450px;">			
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kursus 1</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->kursus_1 : '')?>' name='kursus_1' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Instansi Kursus 1</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_tmp_kursus_1 : '')?>' name='nama_tmp_kursus_1' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat Instansi Kursus 1</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_kursus_1" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_kursus_1 : '')?></textarea>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kursus 2</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->kursus_2 : '')?>' name='kursus_2' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Instansi Kursus 2</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_tmp_kursus_2 : '')?>' name='nama_tmp_kursus_2' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat Instansi Kursus 2</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_kursus_2" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_kursus_2 : '')?></textarea>
					</td>
				</tr>
			</table>
			</fieldset>
			
			<fieldset>
			<legend>Aspek Lain Karyawan</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Masa Kontrak 1</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->masa_kontrak_1 : '')?>' name='masa_kontrak_1' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jabatan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->level_jabatan_1 : '')?>' name='level_jabatan_1' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>	
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Masa Kontrak 2</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->masa_kontrak_2 : '')?>' name='masa_kontrak_2' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jabatan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->level_jabatan_2 : '')?>' name='level_jabatan_2' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;margin-left:30px;width:450px;">			
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Masa Kontrak 3</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->masa_kontrak_3 : '')?>' name='masa_kontrak_3' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jabatan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->level_jabatan_3 : '')?>' name='level_jabatan_3' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			</fieldset>
			
			<fieldset>
			<legend>Hasil Test</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Hasil Test Kualitatif</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->hasil_test_kualitatif : '')?>' name='hasil_test_kualitatif' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Hasil Test Kuantitatif</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->hasil_test_kuantitatif : '')?>' name='hasil_test_kuantitatif' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kesimpulan Test</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="kesimpulan_hasil_test" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->kesimpulan_hasil_test : '')?></textarea>						
					</td>
				</tr>
			</table>
			</fieldset>
			
			<fieldset>
			<legend>Riwayat Kerja</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Perusahaan 1</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_perusahaan_1 : '')?>' name='nama_perusahaan_1' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jabatan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->jabatan_1 : '')?>' name='jabatan_1' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Masa/Lama Kerja</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->masa_kerja_1 : '')?>' name='masa_kerja_1' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Perusahaan 2</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_perusahaan_2 : '')?>' name='nama_perusahaan_2' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jabatan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->jabatan_2 : '')?>' name='jabatan_2' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Masa/Lama Kerja</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->masa_kerja_2 : '')?>' name='masa_kerja_2' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;margin-left:30px;width:450px;">			
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Perusahaan 3</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_perusahaan_3 : '')?>' name='nama_perusahaan_3' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jabatan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->jabatan_3 : '')?>' name='jabatan_3' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Masa/Lama Kerja</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->masa_kerja_3 : '')?>' name='masa_kerja_3' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			</fieldset>
			
			<fieldset>
			<legend>Data Keluarga</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Suami / Istri</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_suami_istri : '')?>' name='nama_suami_istri' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Anak 1</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_anak_1 : '')?>' name='nama_anak_1' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Anak 2</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_anak_2 : '')?>' name='nama_anak_2' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Anak 3</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_anak_3 : '')?>' name='nama_anak_3' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			</fieldset>
						
			<fieldset>
			<legend>Alamat & CP</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. KTP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_ktp : '')?>' name='no_ktp' style="width:200px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat KTP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_ktp" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_ktp : '')?></textarea>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat Karyawan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_karyawan" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_karyawan : '')?></textarea>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Sts Tempat Tinggal</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_status_tmp_tinggal_karyawan' name='id_status_tmp_tinggal_karyawan' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optststmptinggal?>
						</select>
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Contact Person</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->contact_person : '')?>' name='contact_person' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Ponsel CP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_handphone_contact_person : '')?>' name='no_handphone_contact_person' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Hub. Dengan Karyawan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->hubungan_dng_karyawan : '')?>' name='hubungan_dng_karyawan' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat CP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_contact_person" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_contact_person : '')?></textarea>
					</td>
				</tr>
			</table>			
			</fieldset>
			
		</form>
	<?php }elseif($type == "pihak"){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<fieldset>
			<legend>Form Identitas Pihak Ketiga</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Pihak Ketiga</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->kode_pihak3 : '')?>' name='kode_pihak3' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Pihak Ketiga</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_pihak3 : '')?>' name='nama_pihak3' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jenis Kelamin</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='radio' name='jenis_kelamin' <?=$lelaki?> value='L'>&nbsp; Laki-Laki &nbsp;&nbsp;
						<input type='radio' name='jenis_kelamin' <?=$perempuan?> value='P'>&nbsp; Perempuan
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kewarganegaran</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='radio' name='kewarganegaraan' <?=$wni?> value='WNI'>&nbsp; WNI &nbsp;&nbsp;
						<input type='radio' name='kewarganegaraan' <?=$wna?> value='WNA'>&nbsp; WNA
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tempat Lahir</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->tempat_lahir : '')?>' name='tempat_lahir' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Lahir</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select name="tanggal" style="width:85px; border: 1px solid silver; padding: 1px;">
							<?=$opttanggal?>
						</select>
						&nbsp; - &nbsp
						<select name="bulan" style="width:90px; border: 1px solid silver; padding: 1px;">
							<?=$optbulan?>
						</select>
						&nbsp; - &nbsp
						<select name="tahun" style="width:80px; border: 1px solid silver; padding: 1px;">
							<?=$opttahun?>
						</select>
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;margin-left:30px;width:450px;">			
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Agama</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_agama' name='id_agama' style="width:200px; border: 1px solid silver; padding: 1px;">
							<?=$optagama?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status Kawin</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='radio' name='status_kawin' <?=$M?> value='M'>&nbsp; Menikah &nbsp;&nbsp;
						<input type='radio' name='status_kawin' <?=$BM?> value='BM'>&nbsp; Belum Menikah &nbsp;&nbsp;
						<input type='radio' name='status_kawin' <?=$JD?> value='JD'>&nbsp; Janda/Duda
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Telepon</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_telp : '')?>' name='no_telp' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Ponsel</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_handphone : '')?>' name='no_handphone' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Email</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->email : '')?>' name='email' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			</fieldset>
			
			<fieldset>
			<legend>Data Keluarga</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Suami / Istri</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_istri_suami : '')?>' name='nama_istri_suami' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Anak 1</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_anak_1 : '')?>' name='nama_anak_1' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Anak 2</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_anak_2 : '')?>' name='nama_anak_2' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Anak 3</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_anak_3 : '')?>' name='nama_anak_3' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			</fieldset>
			
			<fieldset>
			<legend>Alamat & Contact Person</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. KTP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_ktp : '')?>' name='no_ktp' style="width:200px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat KTP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_ktp" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_ktp : '')?></textarea>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat Pihak Ketiga</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_pihak_ketiga" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_pihak_ketiga : '')?></textarea>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Sts. Tempat Tinggal</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_status_tempat_tinggal' name='id_status_tempat_tinggal' style="width:200px; border: 1px solid silver; padding: 1px;">
							<?=$optststmptinggal?>
						</select>
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;margin-left:30px;width:450px;">			
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Contact Person</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->contact_person : '')?>' name='contact_person' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Hub. Dengan CP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->hubungan_contact_person : '')?>' name='hubungan_contact_person' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat CP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="alamat_contact_person" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->alamat_contact_person : '')?></textarea>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Ponsel CP</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_handphone_contact_person : '')?>' name='no_handphone_contact_person' style="width:150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>			
			</fieldset>
			
		</form>
	<?php }elseif($type == "kas"){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<fieldset>
			<legend>Form Kas Dealer</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Dealer</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_dealer' name='id_group_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupdealer?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Dealer</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_dealer' name='id_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optdealer?>
						</select>
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
				<!-- <tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Kas</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->kode_kas : '')?>' name='kode_kas' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr> -->
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Kas</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_kas : '')?>' name='nama_kas' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Bank</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_bank : '')?>' name='nama_bank' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Account Bank</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->no_account : '')?>' name='no_account' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Account Bank</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_account : '')?>' name='nama_account' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="keterangan" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->keterangan : '')?></textarea>
					</td>
				</tr>				
			</table>			
			</fieldset>			
		</form>
	<?php }elseif($type == "aktiva"){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<fieldset>
			<legend>Form Kas Dealer</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Dealer</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_dealer' name='id_group_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupdealer?>
						</select>
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Dealer</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_dealer' name='id_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optdealer?>
						</select>
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Aktiva</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->kode_aktiva : '')?>' name='kode_aktiva' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Aktiva</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nama_aktiva : '')?>' name='nama_aktiva' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nilai Aktiva</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->nilai_aktiva : '')?>' name='nilai_aktiva' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Quantity</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->quantity : '')?>' name='quantity' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Total Nilai Aktiva</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' value='<?=($editstatus == 'edit' ? $datarecord->total_nilai_aktiva : '')?>' name='total_nilai_aktiva' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Pembelian</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' id='tanggal_pembelian' name='tanggal_pembelian' style="150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Pemakaian</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' id='tanggal_pemakaian' name='tanggal_pemakaian' style="150px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				
			</table>			
			</fieldset>			
		</form>
<!--MASTER BARANG & JASA-->		
	<?php }elseif($type == "warna"){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<fieldset>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Warna</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='nama_warna' value='<?=($editstatus == 'edit' ? $datarecord->nama_warna : '')?>' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status System</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='status' name='status' style="width:200px; border: 1px solid silver; padding: 1px;">
							<?=$optstatuswarna?>
						</select>
					</td>
				</tr>				
			</table>
			</fieldset>
		</form>
	<?php }elseif($type == "motor"){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<fieldset>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:450px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_barang' name='id_group_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupbarang?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kategori Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_kategori_barang' name='id_kategori_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optkategoribarang?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Motor</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='nama_motor' value="<?=($editstatus == 'edit' ? $datarecord->nama_motor : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Pilihan Warna</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='jumlah_pilihan_warna' value="<?=($editstatus == 'edit' ? $datarecord->jumlah_pilihan_warna : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Mesin</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='default_no_mesin' value="<?=($editstatus == 'edit' ? $datarecord->default_no_mesin : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Kerangka</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='default_no_kerangka' value="<?=($editstatus == 'edit' ? $datarecord->default_no_kerangka : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Type Mesin</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='type_mesin' value="<?=($editstatus == 'edit' ? $datarecord->type_mesin : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Dimensi Mesin</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='dimensi_mesin' value="<?=($editstatus == 'edit' ? $datarecord->dimensi_mesin : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Dimensi Langkah</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='dimensi_langkah' value="<?=($editstatus == 'edit' ? $datarecord->dimensi_langkah : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Volume Cylinder</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='volume_cylinder' value="<?=($editstatus == 'edit' ? $datarecord->volume_cylinder : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Susunan Cylinder</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='susunan_silinder' value="<?=($editstatus == 'edit' ? $datarecord->susunan_silinder : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Perbandingan Kompresi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='perbandingan_kompresi' value="<?=($editstatus == 'edit' ? $datarecord->perbandingan_kompresi : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Power Max</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='power_max' value="<?=($editstatus == 'edit' ? $datarecord->power_max : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Torsi Max</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='torsi_max' value="<?=($editstatus == 'edit' ? $datarecord->torsi_max : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Sistem Pelumasan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='sistem_pelumasan' value="<?=($editstatus == 'edit' ? $datarecord->sistem_pelumasan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Oli Mesin</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='oli_mesin' value="<?=($editstatus == 'edit' ? $datarecord->oli_mesin : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Radiator</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='radiator' value="<?=($editstatus == 'edit' ? $datarecord->radiator : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Karburator</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='karburator' value="<?=($editstatus == 'edit' ? $datarecord->karburator : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Putaran Langsam</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='putaran_langsam' value="<?=($editstatus == 'edit' ? $datarecord->putaran_langsam : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Saringan Udara</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='saringan_udara' value="<?=($editstatus == 'edit' ? $datarecord->saringan_udara : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Transmisi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='transmisi' value="<?=($editstatus == 'edit' ? $datarecord->transmisi : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kopling</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='kopling' value="<?=($editstatus == 'edit' ? $datarecord->kopling : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Caster Trail</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='caster_trail' value="<?=($editstatus == 'edit' ? $datarecord->caster_trail : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-left:10px;width:500px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Rasio Gigi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='rasio_gigi' value="<?=($editstatus == 'edit' ? $datarecord->rasio_gigi : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>							
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Sistem Starter</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='sistem_starter' value="<?=($editstatus == 'edit' ? $datarecord->sistem_starter : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Type Rangka</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='type_rangka' value="<?=($editstatus == 'edit' ? $datarecord->type_rangka : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Suspensi Depan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='suspensi_depan' value="<?=($editstatus == 'edit' ? $datarecord->suspensi_depan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Suspensi Belakang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='suspensi_belakang' value="<?=($editstatus == 'edit' ? $datarecord->suspensi_belakang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Rem Depan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='rem_depan' value="<?=($editstatus == 'edit' ? $datarecord->rem_depan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Rem Belakang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='rem_belakang' value="<?=($editstatus == 'edit' ? $datarecord->rem_belakang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Ban Depan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='ban_depan' value="<?=($editstatus == 'edit' ? $datarecord->ban_depan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Ban Belakang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='ban_belakang' value="<?=($editstatus == 'edit' ? $datarecord->ban_belakang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Lampu Depan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='lampu_depan' value="<?=($editstatus == 'edit' ? $datarecord->lampu_depan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Lampu Sein Depan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='lampu_sein_depan' value="<?=($editstatus == 'edit' ? $datarecord->lampu_sein_depan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Lampu Belakang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='lampu_belakang' value="<?=($editstatus == 'edit' ? $datarecord->lampu_belakang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Lampu Sein Belakang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='lampu_sein_belakang' value="<?=($editstatus == 'edit' ? $datarecord->lampu_sein_belakang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Accu / Batterai</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='baterai' value="<?=($editstatus == 'edit' ? $datarecord->baterai : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Busi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='busi' value="<?=($editstatus == 'edit' ? $datarecord->busi : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Sistem Pengapian</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='sistem_pengapian' value="<?=($editstatus == 'edit' ? $datarecord->sistem_pengapian : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Sekring</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='sekring' value="<?=($editstatus == 'edit' ? $datarecord->sekring : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Panjang x Lebar x Tinggi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='panjang_lebar_tinggi' value="<?=($editstatus == 'edit' ? $datarecord->panjang_lebar_tinggi : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tinggi Tempat Duduk</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='tinggi_tempat_duduk' value="<?=($editstatus == 'edit' ? $datarecord->tinggi_tempat_duduk : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jarak Ke Tanah</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='jarak_ke_tanah' value="<?=($editstatus == 'edit' ? $datarecord->jarak_ke_tanah : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kapasitas Tangki</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='kapasitas_tangki' value="<?=($editstatus == 'edit' ? $datarecord->kapasitas_tangki : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Berat Isi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='berat_isi' value="<?=($editstatus == 'edit' ? $datarecord->berat_isi : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Berat Kosong</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='berat_kosong' value="<?=($editstatus == 'edit' ? $datarecord->berat_kosong : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>				
			</table>
			</fieldset>
			
			<fieldset>
				<legend>Harga Beli</legend>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nominal Harga Beli</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="nominal_harga_beli" name='nominal_harga_beli' value="<?=($editstatus == 'edit' ? $datarecord->nominal_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kondisi PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kondisi_ppn_harga_beli' name='kondisi_ppn_harga_beli' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optkondisippnbeli?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">DPP</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="dpp_harga_beli" name='dpp_harga_beli' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->dpp_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='ppn_harga_beli' name='ppn_harga_beli' value="<?=($editstatus == 'edit' ? $datarecord->ppn_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nominal PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="nominal_ppn_harga_beli" name='nominal_ppn_harga_beli' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->nominal_ppn_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>		 
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Beli + PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="harga_beli_plus_ppn" name='harga_beli_plus_ppn' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->harga_beli_plus_ppn : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>				
			</fieldset>
			
			<fieldset>
				<legend>Harga Jual</legend>
				
				<table width="100%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="150px;">Kondisi Harga&nbsp;</th>
							<th>Nominal Harga Jual&nbsp;</th>
							<th align="center">Kondisi PPN&nbsp;</th>
							<th>DPP&nbsp;</th>
							<th>PPN&nbsp;</th>
							<th>Nominal PPN&nbsp;</th>
							<th>Harga Jual + PPN&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 2;
							foreach($hrg_jual as $hrg) : ?>
							<script> numberFormat('<?=$nb?>'); </script>
							<tr id="hrgjual_<?=$nb?>">
								<td>
									<select id='tingkat_hrg_jual_<?=$nb?>' 
										name='tingkat_hrg_jual[]'
										class="tingkat_hrg_jual"
										style="width: 100%; border: 0; padding: 1px; background: none!important;">
										<?=$hrg['opttingkathrgjual']?>
									</select>
								</td>
								<td>
									<input type='text'  
										id='nom_hrg_jual_<?=$nb?>' 
										name='nom_hrg_jual[]' 
										class="nom_hrg_jual"
										value="<?=$hrg['nom_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
										onblur="calculateVal('nom_hrg_jual','<?=$nb?>');">
								</td>
								<td>
									<select id='kondisi_ppn_hrg_jual_<?=$nb?>' 
										name='kondisi_ppn_hrg_jual[]'
										class="kondisi_ppn_hrg_jual"
										style="width: 100%; border: 0; padding: 1px; background: none!important;">
										<?=$hrg['optkondisippn']?>
									</select>
								</td>
								<td>
									<input type='text' 
										id='dpp_hrg_jual_<?=$nb?>' 
										name='dpp_hrg_jual[]'
										class="dpp_hrg_jual"
										disabled="disabled" value="<?=$hrg['dpp_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td>
									<input type='text' 
										id='ppn_hrg_jual_<?=$nb?>' 
										name='ppn_hrg_jual[]'
										class="ppn_hrg_jual"
										value="<?=$hrg['ppn_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
										onblur="calculateVal('ppn_hrg_jual','<?=$nb?>');">
								</td>
								<td>
									<input type='text' 
										id='nom_ppn_hrg_jual_<?=$nb?>' 
										name='nom_ppn_hrg_jual[]' 
										class="nom_ppn_hrg_jual"
										disabled="disabled" 
										value="<?=$hrg['nom_ppn_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td>
									<input type='text' 
										id='hrg_jual_plus_ppn_<?=$nb?>' 
										name='hrg_jual_plus_ppn[]' 
										class="hrg_jual_plus_ppn"
										disabled="disabled" 
										value="<?=$hrg['hrg_jual_plus_ppn']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td align="center" width="50px;">
									<a href="#" style="text-decoration: none;" onclick="add_hrg_jual();">
										<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
									</a>
									<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeEditRow('<?=$nb?>', '<?=$hrg['id']?>');" title="Hapus">
										<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
									</a>
									<input type='hidden' name='id_detil[]' value="<?=$hrg['id']?>" >
									<input type='hidden' name='sts_detil[]' value="add" >
								</td>
							</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr>
							<td>
								<select id='tingkat_hrg_jual_1' 
									name='tingkat_hrg_jual[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$opttingkathrgjual?>
								</select>
							</td>
							<td>
								<input type='text'  
									id='nom_hrg_jual_1' 
									name='nom_hrg_jual[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
									onblur="calculateVal('nom_hrg_jual','1');">
							</td>
							<td>
								<select id='kondisi_ppn_hrg_jual_1' 
									name='kondisi_ppn_hrg_jual[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$optkondisippnjual?>
								</select>
							</td>
							<td>
								<input type='text' 
									id='dpp_hrg_jual_1' 
									name='dpp_hrg_jual[]' 
									disabled="disabled" value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td>
								<input type='text' 
									id='ppn_hrg_jual_1' 
									name='ppn_hrg_jual[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
									onblur="calculateVal('ppn_hrg_jual','1');">
							</td>
							<td>
								<input type='text' 
									id='nom_ppn_hrg_jual_1' 
									name='nom_ppn_hrg_jual[]' 
									disabled="disabled" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td>
								<input type='text' 
									id='hrg_jual_plus_ppn_1' 
									name='hrg_jual_plus_ppn[]' 
									disabled="disabled" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td align="center" width="50px;">
								<a href="#" onclick="add_hrg_jual();">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil[]' value="" >
								<input type='hidden' name='sts_detil[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>	
			</fieldset>
		</form>
	<?php }elseif($type == "sparepart"){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='kode_gambar' value="<?=($editstatus == 'edit' ? $datarecord->kode_gambar : '')?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<input type='hidden' name='jenis_barang' value="0" >
			<fieldset>
			<legend>Identitas Sparepart</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_barang' name='id_group_barang'  style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupbarang?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kategori Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_kategori_barang' name='id_kategori_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optkategoribarang?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Sparepart</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='nama_barang' value="<?=($editstatus == 'edit' ? $datarecord->nama_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Merk Sparepart</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='merek_barang' value="<?=($editstatus == 'edit' ? $datarecord->merek_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Satuan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='satuan_barang' value="<?=($editstatus == 'edit' ? $datarecord->satuan_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Type Sparepart</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='type_barang' value="<?=($editstatus == 'edit' ? $datarecord->type_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			</fieldset>
			<fieldset>
			<legend>Foto Barang</legend>
			<center>
			<table>
				<tr>
				<?php for($i = 0; $i <= 1; $i++) { ?>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:300px">
						<?=$foto[$i]?> <br/>
						<input type='file' name='foto_barang[]' style="width:225px; border: 1px solid silver; padding: 1px;margin-top:2px;"> <br /> <br />
						Keterangan : <input type='text' name='keterangan_gambar[]' value="<?=($editstatus == 'edit' ? $keterangan_foto[$i] : '')?>" style="width:180px; border: 1px solid silver; padding: 1px;">
						<input type="hidden" name="id_foto_barang[]" value="<?=($editstatus == 'edit' ? $id_foto[$i] : '')?>">
					</td>
				<?php } ?>
				</tr>
			</table>
			</center>
			</fieldset>
			<fieldset>
				<legend>Harga Beli</legend>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nominal Harga Beli</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="nominal_harga_beli" name='nominal_harga_beli' value="<?=($editstatus == 'edit' ? $datarecord->nominal_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kondisi PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kondisi_ppn_harga_beli' name='kondisi_ppn_harga_beli' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optkondisippnbeli?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">DPP</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="dpp_harga_beli" name='dpp_harga_beli' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->dpp_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='ppn_harga_beli' name='ppn_harga_beli' value="<?=($editstatus == 'edit' ? $datarecord->ppn_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nominal PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="nominal_ppn_harga_beli" name='nominal_ppn_harga_beli' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->nominal_ppn_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>		
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Beli + PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="harga_beli_plus_ppn" name='harga_beli_plus_ppn' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->harga_beli_plus_ppn : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>		
				</table>				
			</fieldset>
			
			<fieldset>
				<legend>Harga Jual</legend>
				
				<table width="100%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="150px;">Kondisi Harga&nbsp;</th>
							<th>Nominal Harga Jual&nbsp;</th>
							<th align="center">Kondisi PPN&nbsp;</th>
							<th>DPP&nbsp;</th>
							<th>PPN&nbsp;</th>
							<th>Nominal PPN&nbsp;</th>
							<th>Harga Jual + PPN&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 2;
							foreach($hrg_jual as $hrg) : ?>
							<script> numberFormat('<?=$nb?>'); </script>
							<tr id="hrgjual_<?=$nb?>" >
								<td>
									<select id='tingkat_hrg_jual_<?=$nb?>' 
										name='tingkat_hrg_jual[]'
										class="tingkat_hrg_jual"
										style="width: 100%; border: 0; padding: 1px; background: none!important;">
										<?=$hrg['opttingkathrgjual']?>
									</select>
								</td>
								<td>
									<input type='text'  
										id='nom_hrg_jual_<?=$nb?>' 
										name='nom_hrg_jual[]' 
										class="nom_hrg_jual"
										value="<?=$hrg['nom_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
										onblur="calculateVal('nom_hrg_jual','<?=$nb?>');">
								</td>
								<td>
									<select id='kondisi_ppn_hrg_jual_<?=$nb?>' 
										name='kondisi_ppn_hrg_jual[]'
										class="kondisi_ppn_hrg_jual"
										style="width: 100%; border: 0; padding: 1px; background: none!important;">
										<?=$hrg['optkondisippn']?>
									</select>
								</td>
								<td>
									<input type='text' 
										id='dpp_hrg_jual_<?=$nb?>' 
										name='dpp_hrg_jual[]'
										class="dpp_hrg_jual"
										disabled="disabled" value="<?=$hrg['dpp_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td>
									<input type='text' 
										id='ppn_hrg_jual_<?=$nb?>' 
										name='ppn_hrg_jual[]'
										class="ppn_hrg_jual"
										value="<?=$hrg['ppn_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
										onblur="calculateVal('ppn_hrg_jual','<?=$nb?>');">
								</td>
								<td>
									<input type='text' 
										id='nom_ppn_hrg_jual_<?=$nb?>' 
										name='nom_ppn_hrg_jual[]' 
										class="nom_ppn_hrg_jual"
										disabled="disabled" 
										value="<?=$hrg['nom_ppn_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td>
									<input type='text' 
										id='hrg_jual_plus_ppn_<?=$nb?>' 
										name='hrg_jual_plus_ppn[]' 
										class="hrg_jual_plus_ppn"
										disabled="disabled" 
										value="<?=$hrg['hrg_jual_plus_ppn']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td align="center" width="50px;">
									<a href="#" style="text-decoration: none;" onclick="add_hrg_jual();">
										<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
									</a>
									<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeEditRow('<?=$nb?>', '<?=$hrg['id']?>');" title="Hapus">
										<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
									</a>
									<input type='hidden' name='id_detil[]' value="<?=$hrg['id']?>" >
									<input type='hidden' name='sts_detil[]' value="add" >
								</td>
							</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr>
							<td>
								<select id='tingkat_hrg_jual_1' 
									name='tingkat_hrg_jual[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$opttingkathrgjual?>
								</select>
							</td>
							<td>
								<input type='text'  
									id='nom_hrg_jual_1' 
									name='nom_hrg_jual[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
									onblur="calculateVal('nom_hrg_jual','1');">
							</td>
							<td>
								<select id='kondisi_ppn_hrg_jual_1' 
									name='kondisi_ppn_hrg_jual[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$optkondisippnjual?>
								</select>
							</td>
							<td>
								<input type='text' 
									id='dpp_hrg_jual_1' 
									name='dpp_hrg_jual[]' 
									disabled="disabled" value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td>
								<input type='text' 
									id='ppn_hrg_jual_1' 
									name='ppn_hrg_jual[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
									onblur="calculateVal('ppn_hrg_jual','1');">
							</td>
							<td>
								<input type='text' 
									id='nom_ppn_hrg_jual_1' 
									name='nom_ppn_hrg_jual[]' 
									disabled="disabled" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td>
								<input type='text' 
									id='hrg_jual_plus_ppn_1' 
									name='hrg_jual_plus_ppn[]' 
									disabled="disabled" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td align="center" width="50px;">
								<a href="#" onclick="add_hrg_jual();">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil[]' value="" >
								<input type='hidden' name='sts_detil[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>	
			</fieldset>
		</form>
	<?php }elseif($type == "generator"){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<input type='hidden' name='kode_gambar' value="<?=($editstatus == 'edit' ? $datarecord->kode_gambar : '')?>" >
			<input type='hidden' name='jenis_barang' value="1" >
			<fieldset>
			<legend>Identitas Generator</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_barang' name='id_group_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupbarang?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kategori Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_kategori_barang' name='id_kategori_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optkategoribarang?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Generator</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='nama_barang' value="<?=($editstatus == 'edit' ? $datarecord->nama_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Merk Generator</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='merek_barang' value="<?=($editstatus == 'edit' ? $datarecord->merek_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Satuan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='satuan_barang' value="<?=($editstatus == 'edit' ? $datarecord->satuan_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Type Generator</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='type_barang' value="<?=($editstatus == 'edit' ? $datarecord->type_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="keterangan" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'> <?=($editstatus == 'edit' ? $datarecord->keterangan : '')?> </textarea>
					</td>
				</tr>	
			</table>
			</fieldset>
			<fieldset>
			<legend>Foto Barang</legend>
			<center>
			<table>
				<tr>
				<?php for($i = 0; $i <= 1; $i++) { ?>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:300px">
						<?=$foto[$i]?> <br/>
						<input type='file' name='foto_barang[]' style="width:225px; border: 1px solid silver; padding: 1px;margin-top:2px;"> <br /> <br />
						Keterangan : <input type='text' name='keterangan_gambar[]' value="<?=($editstatus == 'edit' ? $keterangan_foto[$i] : '')?>" style="width:180px; border: 1px solid silver; padding: 1px;">
						<input type="hidden" name="id_foto_barang[]" value="<?=($editstatus == 'edit' ? $id_foto[$i] : '')?>">
					</td>
				<?php } ?>
				</tr>
			</table>
			</center>
			</fieldset>
			
			<fieldset>
				<legend>Harga Beli</legend>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nominal Harga Beli</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="nominal_harga_beli" name='nominal_harga_beli' value="<?=($editstatus == 'edit' ? $datarecord->nominal_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kondisi PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kondisi_ppn_harga_beli' name='kondisi_ppn_harga_beli' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optkondisippnbeli?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">DPP</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="dpp_harga_beli" name='dpp_harga_beli' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->dpp_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='ppn_harga_beli' name='ppn_harga_beli' value="<?=($editstatus == 'edit' ? $datarecord->ppn_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nominal PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="nominal_ppn_harga_beli" name='nominal_ppn_harga_beli' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->nominal_ppn_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>		
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Beli + PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="harga_beli_plus_ppn" name='harga_beli_plus_ppn' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->harga_beli_plus_ppn : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>		
				</table>				
			</fieldset>
			
			<fieldset>
				<legend>Harga Jual</legend>
				
				<table width="100%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="150px;">Kondisi Harga&nbsp;</th>
							<th>Nominal Harga Jual&nbsp;</th>
							<th align="center">Kondisi PPN&nbsp;</th>
							<th>DPP&nbsp;</th>
							<th>PPN&nbsp;</th>
							<th>Nominal PPN&nbsp;</th>
							<th>Harga Jual + PPN&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 2;
							foreach($hrg_jual as $hrg) : ?>
							<script> numberFormat('<?=$nb?>'); </script>
							<tr id="hrgjual_<?=$nb?>">
								<td>
									<select id='tingkat_hrg_jual_<?=$nb?>' 
										name='tingkat_hrg_jual[]'
										class="tingkat_hrg_jual"
										style="width: 100%; border: 0; padding: 1px; background: none!important;">
										<?=$hrg['opttingkathrgjual']?>
									</select>
								</td>
								<td>
									<input type='text'  
										id='nom_hrg_jual_<?=$nb?>' 
										name='nom_hrg_jual[]' 
										class="nom_hrg_jual"
										value="<?=$hrg['nom_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
										onblur="calculateVal('nom_hrg_jual','<?=$nb?>');">
								</td>
								<td>
									<select id='kondisi_ppn_hrg_jual_<?=$nb?>' 
										name='kondisi_ppn_hrg_jual[]'
										class="kondisi_ppn_hrg_jual"
										style="width: 100%; border: 0; padding: 1px; background: none!important;">
										<?=$hrg['optkondisippn']?>
									</select>
								</td>
								<td>
									<input type='text' 
										id='dpp_hrg_jual_<?=$nb?>' 
										name='dpp_hrg_jual[]'
										class="dpp_hrg_jual"
										disabled="disabled" value="<?=$hrg['dpp_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td>
									<input type='text' 
										id='ppn_hrg_jual_<?=$nb?>' 
										name='ppn_hrg_jual[]'
										class="ppn_hrg_jual"
										value="<?=$hrg['ppn_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
										onblur="calculateVal('ppn_hrg_jual','<?=$nb?>');">
								</td>
								<td>
									<input type='text' 
										id='nom_ppn_hrg_jual_<?=$nb?>' 
										name='nom_ppn_hrg_jual[]' 
										class="nom_ppn_hrg_jual"
										disabled="disabled" 
										value="<?=$hrg['nom_ppn_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td>
									<input type='text' 
										id='hrg_jual_plus_ppn_<?=$nb?>' 
										name='hrg_jual_plus_ppn[]' 
										class="hrg_jual_plus_ppn"
										disabled="disabled" 
										value="<?=$hrg['hrg_jual_plus_ppn']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td align="center" width="50px;">
									<a href="#" style="text-decoration: none;" onclick="add_hrg_jual();">
										<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
									</a>
									<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeEditRow('<?=$nb?>', '<?=$hrg['id']?>');" title="Hapus">
										<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
									</a>
									<input type='hidden' name='id_detil[]' value="<?=$hrg['id']?>" >
									<input type='hidden' name='sts_detil[]' value="add" >
								</td>
							</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr>
							<td>
								<select id='tingkat_hrg_jual_1' 
									name='tingkat_hrg_jual[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$opttingkathrgjual?>
								</select>
							</td>
							<td>
								<input type='text'  
									id='nom_hrg_jual_1' 
									name='nom_hrg_jual[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
									onblur="calculateVal('nom_hrg_jual','1');">
							</td>
							<td>
								<select id='kondisi_ppn_hrg_jual_1' 
									name='kondisi_ppn_hrg_jual[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$optkondisippnjual?>
								</select>
							</td>
							<td>
								<input type='text' 
									id='dpp_hrg_jual_1' 
									name='dpp_hrg_jual[]' 
									disabled="disabled" value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td>
								<input type='text' 
									id='ppn_hrg_jual_1' 
									name='ppn_hrg_jual[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
									onblur="calculateVal('ppn_hrg_jual','1');">
							</td>
							<td>
								<input type='text' 
									id='nom_ppn_hrg_jual_1' 
									name='nom_ppn_hrg_jual[]' 
									disabled="disabled" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td>
								<input type='text' 
									id='hrg_jual_plus_ppn_1' 
									name='hrg_jual_plus_ppn[]' 
									disabled="disabled" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td align="center" width="50px;">
								<a href="#" onclick="add_hrg_jual();">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil[]' value="" >
								<input type='hidden' name='sts_detil[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>	
			</fieldset>
		</form>
	<?php }elseif($type == "service"){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			
			<fieldset>
			<legend>Group Service</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Service</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_service' name='id_group_service' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupservice?>
						</select>
					</td>
				</tr>			
			</table>
			</fieldset>
			<fieldset>
			<legend>Kategori Service</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">	
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kategori Service</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_kategori_service' name='id_kategori_service' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optkategoriservice?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Ketentuan Jarak Tempuh</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='ketentuan_jarak_tempuh' value="<?=($editstatus == 'edit' ? $datarecord->ketentuan_jarak_tempuh : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Ketentuan Jangka Waktu</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='ketentuan_jangkawaktu_beli' value="<?=($editstatus == 'edit' ? $datarecord->ketentuan_jangkawaktu_beli : '')?>"  style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			</fieldset>
			<fieldset>
			<legend> Jns Serv. & Hrg Jasa </legend>
			<table>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Jenis Service</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='jenis_service' value="<?=($editstatus == 'edit' ? $datarecord->jenis_service : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Jasa - Tingkat 1</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='harga_jasa_tingkat_satu' value="<?=($editstatus == 'edit' ? $datarecord->harga_jasa_tingkat_satu : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Jasa - Tingkat 2</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='harga_jasa_tingkat_dua' value="<?=($editstatus == 'edit' ? $datarecord->harga_jasa_tingkat_dua : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Jasa - Tingkat 3</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='harga_jasa_tingkat_tiga' value="<?=($editstatus == 'edit' ? $datarecord->harga_jasa_tingkat_tiga : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Jasa - Tingkat 4</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='harga_jasa_tingkat_empat' value="<?=($editstatus == 'edit' ? $datarecord->harga_jasa_tingkat_empat : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Jasa - Tingkat 5</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='harga_jasa_tingkat_lima' value="<?=($editstatus == 'edit' ? $datarecord->harga_jasa_tingkat_lima : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
			</table>
			</fieldset>
		</form>
	<?php }elseif($type == "peralatan_service"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<input type='hidden' name='kode_gambar' value="<?=($editstatus == 'edit' ? $datarecord->kode_gambar : '')?>" >
			<input type='hidden' name='jenis_barang' value="2" >
			<fieldset>
			<legend>Id. Alat Service</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_barang' name='id_group_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupbarang?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kategori Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_kategori_barang' name='id_kategori_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optkategoribarang?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Toolkit</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='nama_barang' value="<?=($editstatus == 'edit' ? $datarecord->nama_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Merk Toolkit</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='merek_barang' value="<?=($editstatus == 'edit' ? $datarecord->merek_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Satuan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='satuan_barang' value="<?=($editstatus == 'edit' ? $datarecord->satuan_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Type Toolkit</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='type_barang' value="<?=($editstatus == 'edit' ? $datarecord->type_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Fungsi Toolkit</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='fungsi_barang' value="<?=($editstatus == 'edit' ? $datarecord->fungsi_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jangka Waktu Pemakaian</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='jangka_waktu_pemakaian' value="<?=($editstatus == 'edit' ? $datarecord->jangka_waktu_pemakaian : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="keterangan" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->keterangan : '')?></textarea>
					</td>
				</tr>	
			</table>
			</fieldset>
			<fieldset>
			<legend>Foto Barang</legend>
			<center>
			<table>
				<tr>
				<?php for($i = 0; $i <= 1; $i++) { ?>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:300px">
						<?=$foto[$i]?> <br/>
						<input type='file' name='foto_barang[]' style="width:225px; border: 1px solid silver; padding: 1px;margin-top:2px;"> <br /> <br />
						Keterangan : <input type='text' name='keterangan_gambar[]' value="<?=($editstatus == 'edit' ? $keterangan_foto[$i] : '')?>" style="width:180px; border: 1px solid silver; padding: 1px;">
						<input type="hidden" name="id_foto_barang[]" value="<?=($editstatus == 'edit' ? $id_foto[$i] : '')?>">
					</td>
				<?php } ?>
				</tr>
			</table>
			</center>
			</fieldset>
			
			<fieldset>
				<legend>Harga Beli</legend>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nominal Harga Beli</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="nominal_harga_beli" name='nominal_harga_beli' value="<?=($editstatus == 'edit' ? $datarecord->nominal_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kondisi PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kondisi_ppn_harga_beli' name='kondisi_ppn_harga_beli' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optkondisippnbeli?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">DPP</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="dpp_harga_beli" name='dpp_harga_beli' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->dpp_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='ppn_harga_beli' name='ppn_harga_beli' value="<?=($editstatus == 'edit' ? $datarecord->ppn_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nominal PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="nominal_ppn_harga_beli" name='nominal_ppn_harga_beli' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->nominal_ppn_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>		
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Beli + PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="harga_beli_plus_ppn" name='harga_beli_plus_ppn' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->harga_beli_plus_ppn : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>		
				</table>				
			</fieldset>
			
			<fieldset>
				<legend>Harga Jual</legend>
				
				<table width="100%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="150px;">Kondisi Harga&nbsp;</th>
							<th>Nominal Harga Jual&nbsp;</th>
							<th align="center">Kondisi PPN&nbsp;</th>
							<th>DPP&nbsp;</th>
							<th>PPN&nbsp;</th>
							<th>Nominal PPN&nbsp;</th>
							<th>Harga Jual + PPN&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 2;
							foreach($hrg_jual as $hrg) : ?>
							<script> numberFormat('<?=$nb?>'); </script>
							<tr id="hrgjual_<?=$nb?>">
								<td>
									<select id='tingkat_hrg_jual_<?=$nb?>' 
										name='tingkat_hrg_jual[]'
										class="tingkat_hrg_jual"
										style="width: 100%; border: 0; padding: 1px; background: none!important;">
										<?=$hrg['opttingkathrgjual']?>
									</select>
								</td>
								<td>
									<input type='text'  
										id='nom_hrg_jual_<?=$nb?>' 
										name='nom_hrg_jual[]' 
										class="nom_hrg_jual"
										value="<?=$hrg['nom_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
										onblur="calculateVal('nom_hrg_jual','<?=$nb?>');">
								</td>
								<td>
									<select id='kondisi_ppn_hrg_jual_<?=$nb?>' 
										name='kondisi_ppn_hrg_jual[]'
										class="kondisi_ppn_hrg_jual"
										style="width: 100%; border: 0; padding: 1px; background: none!important;">
										<?=$hrg['optkondisippn']?>
									</select>
								</td>
								<td>
									<input type='text' 
										id='dpp_hrg_jual_<?=$nb?>' 
										name='dpp_hrg_jual[]'
										class="dpp_hrg_jual"
										disabled="disabled" value="<?=$hrg['dpp_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td>
									<input type='text' 
										id='ppn_hrg_jual_<?=$nb?>' 
										name='ppn_hrg_jual[]'
										class="ppn_hrg_jual"
										value="<?=$hrg['ppn_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
										onblur="calculateVal('ppn_hrg_jual','<?=$nb?>');">
								</td>
								<td>
									<input type='text' 
										id='nom_ppn_hrg_jual_<?=$nb?>' 
										name='nom_ppn_hrg_jual[]' 
										class="nom_ppn_hrg_jual"
										disabled="disabled" 
										value="<?=$hrg['nom_ppn_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td>
									<input type='text' 
										id='hrg_jual_plus_ppn_<?=$nb?>' 
										name='hrg_jual_plus_ppn[]' 
										class="hrg_jual_plus_ppn"
										disabled="disabled" 
										value="<?=$hrg['hrg_jual_plus_ppn']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td align="center" width="50px;">
									<a href="#" style="text-decoration: none;" onclick="add_hrg_jual();">
										<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
									</a>
									<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeEditRow('<?=$nb?>', '<?=$hrg['id']?>');" title="Hapus">
										<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
									</a>
									<input type='hidden' name='id_detil[]' value="<?=$hrg['id']?>" >
									<input type='hidden' name='sts_detil[]' value="add" >
								</td>
							</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr>
							<td>
								<select id='tingkat_hrg_jual_1' 
									name='tingkat_hrg_jual[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$opttingkathrgjual?>
								</select>
							</td>
							<td>
								<input type='text'  
									id='nom_hrg_jual_1' 
									name='nom_hrg_jual[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
									onblur="calculateVal('nom_hrg_jual','1');">
							</td>
							<td>
								<select id='kondisi_ppn_hrg_jual_1' 
									name='kondisi_ppn_hrg_jual[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$optkondisippnjual?>
								</select>
							</td>
							<td>
								<input type='text' 
									id='dpp_hrg_jual_1' 
									name='dpp_hrg_jual[]' 
									disabled="disabled" value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td>
								<input type='text' 
									id='ppn_hrg_jual_1' 
									name='ppn_hrg_jual[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
									onblur="calculateVal('ppn_hrg_jual','1');">
							</td>
							<td>
								<input type='text' 
									id='nom_ppn_hrg_jual_1' 
									name='nom_ppn_hrg_jual[]' 
									disabled="disabled" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td>
								<input type='text' 
									id='hrg_jual_plus_ppn_1' 
									name='hrg_jual_plus_ppn[]' 
									disabled="disabled" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td align="center" width="50px;">
								<a href="#" onclick="add_hrg_jual();">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil[]' value="" >
								<input type='hidden' name='sts_detil[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>	
			</fieldset>
		</form>
	<?php }elseif($type == "barang_promosi"){ ?>
		<form  method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
			<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
			<input type='hidden' name='kode_gambar' value="<?=($editstatus == 'edit' ? $datarecord->kode_gambar : '')?>" >
			<input type='hidden' name='jenis_barang' value="3" >
			<fieldset>
			<legend>Id. Barang Promosi</legend>
			<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_group_barang' name='id_group_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optgroupbarang?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kategori Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<select id='id_kategori_barang' name='id_kategori_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
							<?=$optkategoribarang?>
						</select>
					</td>
				</tr>				
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Barang Promosi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='nama_barang' value="<?=($editstatus == 'edit' ? $datarecord->nama_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Merk Barang Promosi</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='merek_barang' value="<?=($editstatus == 'edit' ? $datarecord->merek_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Satuan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='satuan_barang' value="<?=($editstatus == 'edit' ? $datarecord->satuan_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Type Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='type_barang' value="<?=($editstatus == 'edit' ? $datarecord->type_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Fungsi Barang</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='fungsi_barang' value="<?=($editstatus == 'edit' ? $datarecord->fungsi_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jangka Waktu Pemakaian</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='jangka_waktu_pemakaian' value="<?=($editstatus == 'edit' ? $datarecord->jangka_waktu_pemakaian : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr>
				<!-- <tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Beli</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<input type='text' name='harga_beli' style="width:296px; border: 1px solid silver; padding: 1px;">
					</td>
				</tr> -->
				<tr>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
						<textarea name="keterangan" style="width:296px; border: 1px solid silver; padding: 1px;" rows='2'><?=($editstatus == 'edit' ? $datarecord->keterangan : '')?></textarea>
					</td>
				</tr>	
			</table>
			</fieldset>
			<fieldset>
			<legend>Foto Barang</legend>
			<center>
			<table>
				<tr>
				<?php for($i = 0; $i <= 1; $i++) { ?>
					<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:300px">
						<?=$foto[$i]?> <br/>
						<input type='file' name='foto_barang[]' style="width:225px; border: 1px solid silver; padding: 1px;margin-top:2px;"> <br /> <br />
						Keterangan : <input type='text' name='keterangan_gambar[]' value="<?=($editstatus == 'edit' ? $keterangan_foto[$i] : '')?>" style="width:180px; border: 1px solid silver; padding: 1px;">
						<input type="hidden" name="id_foto_barang[]" value="<?=($editstatus == 'edit' ? $id_foto[$i] : '')?>">
					</td>
				<?php } ?>
				</tr>
			</table>
			</center>
			</fieldset>
			
			<fieldset>
				<legend>Harga Beli</legend>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nominal Harga Beli</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="nominal_harga_beli" name='nominal_harga_beli' value="<?=($editstatus == 'edit' ? $datarecord->nominal_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kondisi PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kondisi_ppn_harga_beli' name='kondisi_ppn_harga_beli' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optkondisippnbeli?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">DPP</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="dpp_harga_beli" name='dpp_harga_beli' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->dpp_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='ppn_harga_beli' name='ppn_harga_beli' value="<?=($editstatus == 'edit' ? $datarecord->ppn_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nominal PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="nominal_ppn_harga_beli" name='nominal_ppn_harga_beli' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->nominal_ppn_harga_beli : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>		
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Beli + PPN</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id="harga_beli_plus_ppn" name='harga_beli_plus_ppn' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->harga_beli_plus_ppn : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>		
				</table>				
			</fieldset>
			
			<fieldset>
				<legend>Harga Jual</legend>
				
				<table width="100%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="150px;">Kondisi Harga&nbsp;</th>
							<th>Nominal Harga Jual&nbsp;</th>
							<th align="center">Kondisi PPN&nbsp;</th>
							<th>DPP&nbsp;</th>
							<th>PPN&nbsp;</th>
							<th>Nominal PPN&nbsp;</th>
							<th>Harga Jual + PPN&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 2;
							foreach($hrg_jual as $hrg) : ?>
							<script> numberFormat('<?=$nb?>'); </script>
							<tr id="hrgjual_<?=$nb?>">
								<td>
									<select id='tingkat_hrg_jual_<?=$nb?>' 
										name='tingkat_hrg_jual[]'
										class="tingkat_hrg_jual"
										style="width: 100%; border: 0; padding: 1px; background: none!important;">
										<?=$hrg['opttingkathrgjual']?>
									</select>
								</td>
								<td>
									<input type='text'  
										id='nom_hrg_jual_<?=$nb?>' 
										name='nom_hrg_jual[]' 
										class="nom_hrg_jual"
										value="<?=$hrg['nom_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
										onblur="calculateVal('nom_hrg_jual','<?=$nb?>');">
								</td>
								<td>
									<select id='kondisi_ppn_hrg_jual_<?=$nb?>' 
										name='kondisi_ppn_hrg_jual[]'
										class="kondisi_ppn_hrg_jual"
										style="width: 100%; border: 0; padding: 1px; background: none!important;">
										<?=$hrg['optkondisippn']?>
									</select>
								</td>
								<td>
									<input type='text' 
										id='dpp_hrg_jual_<?=$nb?>' 
										name='dpp_hrg_jual[]'
										class="dpp_hrg_jual"
										disabled="disabled" value="<?=$hrg['dpp_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td>
									<input type='text' 
										id='ppn_hrg_jual_<?=$nb?>' 
										name='ppn_hrg_jual[]'
										class="ppn_hrg_jual"
										value="<?=$hrg['ppn_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
										onblur="calculateVal('ppn_hrg_jual','<?=$nb?>');">
								</td>
								<td>
									<input type='text' 
										id='nom_ppn_hrg_jual_<?=$nb?>' 
										name='nom_ppn_hrg_jual[]' 
										class="nom_ppn_hrg_jual"
										disabled="disabled" 
										value="<?=$hrg['nom_ppn_hrg_jual']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td>
									<input type='text' 
										id='hrg_jual_plus_ppn_<?=$nb?>' 
										name='hrg_jual_plus_ppn[]' 
										class="hrg_jual_plus_ppn"
										disabled="disabled" 
										value="<?=$hrg['hrg_jual_plus_ppn']?>" 
										style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
								</td>
								<td align="center" width="50px;">
									<a href="#" style="text-decoration: none;" onclick="add_hrg_jual();">
										<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
									</a>
									<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeEditRow('<?=$nb?>', '<?=$hrg['id']?>');" title="Hapus">
										<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
									</a>
									<input type='hidden' name='id_detil[]' value="<?=$hrg['id']?>" >
									<input type='hidden' name='sts_detil[]' value="add" >
								</td>
							</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr>
							<td>
								<select id='tingkat_hrg_jual_1' 
									name='tingkat_hrg_jual[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$opttingkathrgjual?>
								</select>
							</td>
							<td>
								<input type='text'  
									id='nom_hrg_jual_1' 
									name='nom_hrg_jual[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
									onblur="calculateVal('nom_hrg_jual','1');">
							</td>
							<td>
								<select id='kondisi_ppn_hrg_jual_1' 
									name='kondisi_ppn_hrg_jual[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$optkondisippnjual?>
								</select>
							</td>
							<td>
								<input type='text' 
									id='dpp_hrg_jual_1' 
									name='dpp_hrg_jual[]' 
									disabled="disabled" value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td>
								<input type='text' 
									id='ppn_hrg_jual_1' 
									name='ppn_hrg_jual[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;"
									onblur="calculateVal('ppn_hrg_jual','1');">
							</td>
							<td>
								<input type='text' 
									id='nom_ppn_hrg_jual_1' 
									name='nom_ppn_hrg_jual[]' 
									disabled="disabled" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td>
								<input type='text' 
									id='hrg_jual_plus_ppn_1' 
									name='hrg_jual_plus_ppn[]' 
									disabled="disabled" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;">
							</td>
							<td align="center" width="50px;">
								<a href="#" onclick="add_hrg_jual();">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil[]' value="" >
								<input type='hidden' name='sts_detil[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>	
			</fieldset>
		</form>
	<?php }elseif($type == "proses_promosi_unit"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
				<legend>Program Promosi</legend>
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<input type='hidden' name='jenis_promosi' value="<?=($editstatus == 'edit' ? $datarecord->jenis_promosi : 'pr_unit')?>" >
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Program Promosi</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_promosi' class="datebox" name='tgl_promosi' value="<?=($editstatus == 'edit' ? $datarecord->tgl_promosi : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Program Promosi</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='nama_promosi' name='nama_promosi' value="<?=($editstatus == 'edit' ? $datarecord->nama_promosi : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Memo Prog Promosi</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='no_memo' name='no_memo' value="<?=($editstatus == 'edit' ? $datarecord->no_memo : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">All Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='promosi_all_dealer' onchange="getpromodealer(this);" name='promosi_all_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optalldealer?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jenis Pejualan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='jenis_penjualan' name='jenis_penjualan' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optjenispenjualan?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Pembiayaan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type="text" id='pembiayaan' name='pembiayaan' disabled="disabled" value="<?=($editstatus == 'edit' ? $datarecord->pembiayaan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px; background: #cdcdcd;">
						</td>
					</tr>
				</table>

				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Mulai Tanggal</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_mulai' class="datebox" name='tgl_mulai' value="<?=($editstatus == 'edit' ? $datarecord->tgl_mulai : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Berakhir Tanggal</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_berakhir' class="datebox" name='tgl_berakhir' value="<?=($editstatus == 'edit' ? $datarecord->tgl_berakhir : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Masa Berlaku</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value="0" id='masa_berlaku_bln' name='masa_berlaku_bln' disabled style="width:36px; border: 1px solid silver; padding: 1px; text-align: right;"> Bulan &nbsp;
							<input type='text' value="0" id='masa_berlaku_hari' name='masa_berlaku_hari' disabled style="width:36px; border: 1px solid silver; padding: 1px; text-align: right;"> Hari
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<textarea id="keterangan" style="width: 296px; border: 1px solid silver; padding: 1px;" name="keterangan"><?=($editstatus == 'edit' ? $datarecord->keterangan : '')?></textarea>
						</td>
					</tr>
				</table>
			</fieldset>
			
			<fieldset id="promosi_dealer" style="display: none;">
				<legend>Dealer Promosi</legend>
				<table width="40%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="200px;">Group Dealer&nbsp;</th>
							<th>Nama Dealer&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 100;
							foreach($prodealer as $deal) : ?>
								<tr id="promodealer_<?=$nb?>">
									<iframe style="display: none;" 
										onload="getDealer('<?=$deal['group_promosi_dealer']?>','<?=$deal['promosi_dealer']?>','<?=$nb?>');">
									</iframe>
									<td>
										<select id='group_promosi_dealer_<?=$nb?>' onchange="changeGroupDealer('<?=$nb?>');"
											name='group_promosi_dealer[]' 
											style="width: 100%; border: 0; padding: 1px; background: none!important;">
											<?=$deal['optgroupdealer']?>
										</select>
									</td>
									<td>
										<select id='promosi_dealer_<?=$nb?>' 
											name='promosi_dealer[]' 
											style="width: 100%; border: 0; padding: 1px; background: none!important;">
											<option value="">-- Pilih --</option>
										</select>
									</td>
									<td align="center" width="50px;">
										<a href="#" style="text-decoration: none;" onclick="addRows('dealer');">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
										</a>
										<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeRows('dealer','<?=$nb?>', '<?=$deal['id']?>');" title="Hapus">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
										</a>
										<input type='hidden' name='id_detil[]' value="<?=$deal['id']?>" >
										<input type='hidden' name='sts_detil[]' value="add" >
									</td>
								</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr id="promodealer_1" >
							<td>
								<select id='group_promosi_dealer_1' onchange="changeGroupDealer('1');"
									name='group_promosi_dealer[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<?=$optdealerpromo?>
								</select>
							</td>
							<td>
								<select id='promosi_dealer_1' 
									name='promosi_dealer[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;">
									<option value="">-- Pilih --</option>
								</select>
							</td>
							<td align="center" width="50px;">
								<a href="#" onclick="addRows('dealer');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil[]' value="" >
								<input type='hidden' name='sts_detil[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>	
			</fieldset>
			<fieldset id="kredit_dealer" style="display: none;">
				<legend>Data Support Kredit Dealer</legend>
				<table width="40%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="200px;">Nama Barang&nbsp;</th>
							<th>Nilai Discount&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body_kd">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 100;
							foreach($kdealer as $kd) : ?>
								<tr id="kreditdealer_<?=$nb?>">
									<td>
										<input type='text' 
											id='nama_barang_KD_<?=$nb?>' 
											name='nama_barang_KD[]' 
											value="<?=$kd['nama_barang_KD']?>"
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='nilai_discount_<?=$nb?>' 
											name='nilai_discount[]'
											value="<?=$kd['nilai_discount']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td align="center" width="50px;">
										<a href="#" style="text-decoration: none;" onclick="addRows('kd');">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
										</a>
										<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeRows('kd','<?=$nb?>', '<?=$kd['id']?>');" title="Hapus">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
										</a>
										<input type='hidden' name='id_detil3[]' value="<?=$kd['id']?>" >
										<input type='hidden' name='sts_detil3[]' value="add" >
									</td>
								</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr id="kreditdealer_1" >
							<td>
								<input type='text' 
									id='nama_barang_KD_1' 
									name='nama_barang_KD[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='nilai_discount_1' 
									name='nilai_discount[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td align="center" width="50px;">
								<a href="#" onclick="addRows('kd');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil3[]' value="" >
								<input type='hidden' name='sts_detil3[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>	
			</fieldset>
			<fieldset id="kredit_leasing" style="display: none;">
				<legend>Data Support Kredit Leasing</legend>
				<table width="100%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="150">Nama Barang&nbsp;</th>
							<th width="50">Kondisi Uang Muka&nbsp;</th>
							<th width="50">Tenor&nbsp;</th>
							<th>Nilai Subsidi&nbsp;</th>
							<th width="50">Tenor&nbsp;</th>
							<th>Nilai Subsidi&nbsp;</th>
							<th width="50">Tenor&nbsp;</th>
							<th>Nilai Subsidi&nbsp;</th>
							<th width="50">Tenor&nbsp;</th>
							<th>Nilai Subsidi&nbsp;</th>
							<th width="50">Tenor&nbsp;</th>
							<th>Nilai Subsidi&nbsp;</th>
							<th width="50">Tenor&nbsp;</th>
							<th>Nilai Subsidi&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body_kl">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 100;
							foreach($kleasing as $kl) : ?>
								<tr id="kreditleasing_<?=$nb?>">
									<td>
										<input type='text' 
											id='nama_barang_KL_<?=$nb?>' 
											name='nama_barang_KL[]' 
											value="<?=$kl['nama_barang_KL']?>"
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='kondisi_uang_muka_<?=$nb?>' 
											name='kondisi_uang_muka[]' 
											value="<?=$kl['kondisi_uang_muka']?>"
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='tenor_a_<?=$nb?>' 
											name='tenor_a[]' 
											value="<?=$kl['tenor_a']?>"
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='nilai_subsidi_a_<?=$nb?>' 
											name='nilai_subsidi_a[]'
											value="<?=$kl['nilai_subsidi_a']?>"
											class="getCurrency"
											onchange="currencyFormat(this);"
											style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='tenor_b_<?=$nb?>' 
											name='tenor_b[]'
											value="<?=$kl['tenor_b']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='nilai_subsidi_b_<?=$nb?>' 
											name='nilai_subsidi_b[]'
											value="<?=$kl['nilai_subsidi_b']?>" 
											class="getCurrency"
											onchange="currencyFormat(this);"
											style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='tenor_c_<?=$nb?>' 
											name='tenor_c[]'
											value="<?=$kl['tenor_c']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='nilai_subsidi_c_<?=$nb?>' 
											name='nilai_subsidi_c[]' 
											value="<?=$kl['nilai_subsidi_c']?>"
											class="getCurrency"
											onchange="currencyFormat(this);"
											style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='tenor_d_<?=$nb?>' 
											name='tenor_d[]'
											value="<?=$kl['tenor_d']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='nilai_subsidi_d_<?=$nb?>' 
											name='nilai_subsidi_d[]' 
											value="<?=$kl['nilai_subsidi_d']?>"
											class="getCurrency"
											onchange="currencyFormat(this);"
											style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='tenor_e_<?=$nb?>' 
											name='tenor_e[]'
											value="<?=$kl['tenor_e']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='nilai_subsidi_e_<?=$nb?>' 
											name='nilai_subsidi_e[]' 
											value="<?=$kl['nilai_subsidi_e']?>"
											class="getCurrency"
											onchange="currencyFormat(this);"
											style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='tenor_f_<?=$nb?>' 
											name='tenor_f[]'
											value="<?=$kl['tenor_f']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='nilai_subsidi_f_<?=$nb?>' 
											name='nilai_subsidi_f[]' 
											value="<?=$kl['nilai_subsidi_f']?>"
											class="getCurrency"
											onchange="currencyFormat(this);"
											style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
									</td>
									<td align="center" width="50px;">
										<a href="#" style="text-decoration: none;" onclick="addRows('kl');">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
										</a>
										<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeRows('kl','<?=$nb?>', '<?=$kl['id']?>');" title="Hapus">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
										</a>
										<input type='hidden' name='id_detil4[]' value="<?=$kl['id']?>" >
										<input type='hidden' name='sts_detil4[]' value="add" >
									</td>
								</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>

						<tr id="kreditleasing_1" >
							<td>
								<input type='text' 
									id='nama_barang_KL_1' 
									name='nama_barang_KL[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='kondisi_uang_muka_1' 
									name='kondisi_uang_muka[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='tenor_a_1' 
									name='tenor_a[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='nilai_subsidi_a_1' 
									name='nilai_subsidi_a[]' 
									class="getCurrency" onchange="currencyFormat(this);"
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='tenor_b_1' 
									name='tenor_b[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='nilai_subsidi_b_1' 
									name='nilai_subsidi_b[]' 
									class="getCurrency" onchange="currencyFormat(this);"
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='tenor_c_1' 
									name='tenor_c[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='nilai_subsidi_c_1' 
									name='nilai_subsidi_c[]'
									class="getCurrency" onchange="currencyFormat(this);" 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='tenor_d_1' 
									name='tenor_d[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='nilai_subsidi_d_1' 
									name='nilai_subsidi_d[]'
									class="getCurrency" onchange="currencyFormat(this);" 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='tenor_e_1' 
									name='tenor_e[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='nilai_subsidi_e_1' 
									name='nilai_subsidi_e[]'
									class="getCurrency" onchange="currencyFormat(this);" 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='tenor_f_1' 
									name='tenor_f[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='nilai_subsidi_f_1' 
									name='nilai_subsidi_f[]'
									class="getCurrency" onchange="currencyFormat(this);" 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>

							<td align="center" width="50px;">
								<a href="#" onclick="addRows('kl');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil4[]' value="" >
								<input type='hidden' name='sts_detil4[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>	
			</fieldset>
			<fieldset id="data_support" style="display: none;">
				<legend>Data Support Hadiah Langsung</legend>
				<table width="100%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="150">Nama Barang&nbsp;</th>
							<th width="150">Nama Barang Hadiah&nbsp;</th>
							<th width="50">Qty&nbsp;</th>
							<th width="150">Nama Barang Hadiah&nbsp;</th>
							<th width="50">Qty&nbsp;</th>
							<th width="150">Nama Barang Hadiah&nbsp;</th>
							<th width="50">Qty&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body_hadiah">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 100;
							foreach($hadiah as $hd) : ?>
								<tr id="datahadiah_<?=$nb?>">
									<td>
										<input type='text' 
											id='brg_promosi_<?=$nb?>' 
											name='brg_promosi[]' 
											value="<?=$hd['brg_promosi']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='brg_hadiah_a_<?=$nb?>' 
											name='brg_hadiah_a[]' 
											value="<?=$hd['brg_hadiah_a']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='qty_hadiah_a_<?=$nb?>' 
											name='qty_hadiah_a[]' 
											value="<?=$hd['qty_hadiah_a']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='brg_hadiah_b_<?=$nb?>' 
											name='brg_hadiah_b[]' 
											value="<?=$hd['brg_hadiah_b']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='qty_hadiah_b_<?=$nb?>' 
											name='qty_hadiah_b[]' 
											value="<?=$hd['qty_hadiah_b']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='brg_hadiah_c_<?=$nb?>' 
											name='brg_hadiah_c[]' 
											value="<?=$hd['brg_hadiah_c']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='qty_hadiah_c_<?=$nb?>' 
											name='qty_hadiah_c[]' 
											value="<?=$hd['qty_hadiah_c']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
									</td>
									<td align="center" width="50px;">
										<a href="#" style="text-decoration: none;" onclick="addRows('hadiah');">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
										</a>
										<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeRows('hadiah',<?=$nb?>', '<?=$hd['id']?>');" title="Hapus">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
										</a>
										<input type='hidden' name='id_detil2[]' value="<?=$hd['id']?>" >
										<input type='hidden' name='sts_detil2[]' value="add" >
									</td>
								</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr id="datahadiah_1" >
							<td>
								<input type='text' 
									id='brg_promosi_1' 
									name='brg_promosi[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='brg_hadiah_a_1' 
									name='brg_hadiah_a[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='qty_hadiah_a_1' 
									name='qty_hadiah_a[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='brg_hadiah_b_1' 
									name='brg_hadiah_b[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='qty_hadiah_b_1' 
									name='qty_hadiah_b[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='brg_hadiah_c_1' 
									name='brg_hadiah_c[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='qty_hadiah_c_1' 
									name='qty_hadiah_c[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; text-align: right;" />
							</td>
							<td align="center" width="50px;">
								<a href="#" onclick="addRows('hadiah');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil2[]' value="" >
								<input type='hidden' name='sts_detil2[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "proses_promosi_service"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
				<legend>Program Promosi</legend>
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<input type='hidden' name='jenis_promosi' value="<?=($editstatus == 'edit' ? $datarecord->jenis_promosi : 'pr_service')?>" >
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Program Promosi</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_promosi' class="datebox" name='tgl_promosi' value="<?=($editstatus == 'edit' ? $datarecord->tgl_promosi : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Group Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_group_dealer' name='id_group_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optgroupdealer?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_dealer' name='id_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
								<option value=''>-- Pilih --</option>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Memo Prog Promosi</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='no_memo' name='no_memo' value="<?=($editstatus == 'edit' ? $datarecord->no_memo : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Program Promosi</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='nama_promosi' name='nama_promosi' value="<?=($editstatus == 'edit' ? $datarecord->nama_promosi : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>

				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Mulai Tanggal</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_mulai' class="datebox" name='tgl_mulai' value="<?=($editstatus == 'edit' ? $datarecord->tgl_mulai : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Berakhir Tanggal</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_berakhir' class="datebox" name='tgl_berakhir' value="<?=($editstatus == 'edit' ? $datarecord->tgl_berakhir : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Masa Berlaku</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value="0" id='masa_berlaku_bln' name='masa_berlaku_bln' disabled style="width:36px; border: 1px solid silver; padding: 1px; text-align: right;"> Bulan &nbsp;
							<input type='text' value="0" id='masa_berlaku_hari' name='masa_berlaku_hari' disabled style="width:36px; border: 1px solid silver; padding: 1px; text-align: right;"> Hari
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<textarea id="keterangan" style="width: 296px; border: 1px solid silver; padding: 1px;" name="keterangan"><?=($editstatus == 'edit' ? $datarecord->keterangan : '')?></textarea>
						</td>
					</tr>
				</table>
			</fieldset>
			<fieldset>
				<legend>Data Barang & Service</legend>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_group_barang' name='id_group_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optgroupbarang?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kategori Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_kategori_barang' name='id_kategori_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
								<option value=''>-- Pilih --</option>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='nama_barang' name='nama_barang' value="<?=($editstatus == 'edit' ? $datarecord->nama_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Service</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_group_service' name='id_group_service' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optgroupservice?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kategori Service</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_kategori_service' name='id_kategori_service' style="width:300px; border: 1px solid silver; padding: 1px;">
								<option value=''>-- Pilih --</option>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Jenis Service</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='nama_service' name='nama_service' value="<?=($editstatus == 'edit' ? $datarecord->nama_service : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
			</fieldset>
			<fieldset>
				<legend>Hadiah Langsung</legend>
				<table width="55%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="100">Kategori Barang&nbsp;</th>
							<th width="200">Nama Barang&nbsp;</th>
							<th width="50">Qty&nbsp;</th>
							<th width="100">Satuan&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body_hadiah_lsg">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 100;
							foreach($hadiah_lsg as $hd) : ?>
								<tr id="hadiah_lsg_<?=$nb?>">
									<td>
										<select id='kategori_barang_hadiah_1' name='kategori_barang_hadiah[]' style="width:170px; background: transparent; border: none; padding: 1px;">
											<?=$hd['optkategoribarang']?>
										</select>
									</td>
									<td>
										<input type='text' 
											id='nama_barang_hadiah_1' 
											name='nama_barang_hadiah[]' 
											value="<?=$hd['nama_barang_hadiah']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='qty_1' 
											name='qty_barang[]' 
											value="<?=$hd['qty_barang']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<select id='satuan_1' name='satuan[]' style="width:170px; border: none; padding: 1px;">
											<?=$hd['optsatuan']?>
										</select>
									</td>
									<td align="center" width="50px;">
										<a href="#" style="text-decoration: none;" onclick="addRows('hadiah_lsg');">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
										</a>
										<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeRows('hadiah_lsg','<?=$nb?>', '<?=$hd['id']?>');" title="Hapus">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
										</a>
										<input type='hidden' name='id_detil[]' value="<?=$hd['id']?>" >
										<input type='hidden' name='sts_detil[]' value="add" >
									</td>
								</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr id="hadiah_lsg_1" >
							<td>
								<select id='kategori_barang_hadiah_1' name='kategori_barang_hadiah[]' style="width:170px; background: transparent; border: none; padding: 1px;">
									<?=$optkategoribarang?>
								</select>
							</td>
							<td>
								<input type='text' 
									id='nama_barang_hadiah_1' 
									name='nama_barang_hadiah[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='qty_1' 
									name='qty_barang[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<select id='satuan_1' name='satuan[]' style="width:170px; border: none; padding: 1px;">
									<?=$optsatuan?>
								</select>
							</td>
							
							<td align="center" width="50px;">
								<a href="#" onclick="addRows('hadiah_lsg');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil[]' value="" >
								<input type='hidden' name='sts_detil[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "proses_promosi_sparepart"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
				<legend>Program Promosi</legend>
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<input type='hidden' name='jenis_promosi' value="<?=($editstatus == 'edit' ? $datarecord->jenis_promosi : 'pr_sparepart')?>" >
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Program Promosi</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_promosi' class="datebox" name='tgl_promosi' value="<?=($editstatus == 'edit' ? $datarecord->tgl_promosi : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Surat Prog Promosi</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='no_memo' name='no_memo' value="<?=($editstatus == 'edit' ? $datarecord->no_memo : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Program Promosi</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='nama_promosi' name='nama_promosi' value="<?=($editstatus == 'edit' ? $datarecord->nama_promosi : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Mulai Tanggal</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_mulai' class="datebox" name='tgl_mulai' value="<?=($editstatus == 'edit' ? $datarecord->tgl_mulai : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Berakhir Tanggal</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_berakhir' class="datebox" name='tgl_berakhir' value="<?=($editstatus == 'edit' ? $datarecord->tgl_berakhir : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Masa Berlaku</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' value="0" id='masa_berlaku_bln' name='masa_berlaku_bln' disabled style="width:36px; border: 1px solid silver; padding: 1px; text-align: right;"> Bulan &nbsp;
							<input type='text' value="0" id='masa_berlaku_hari' name='masa_berlaku_hari' disabled style="width:36px; border: 1px solid silver; padding: 1px; text-align: right;"> Hari
						</td>
					</tr>
				</table>

				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan 1</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<textarea id="keterangan" style="width: 296px; border: 1px solid silver; padding: 1px;" name="keterangan"><?=($editstatus == 'edit' ? $datarecord->keterangan : '')?></textarea>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan 2</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<textarea id="keterangan2" style="width: 296px; border: 1px solid silver; padding: 1px;" name="keterangan2"><?=($editstatus == 'edit' ? $datarecord->keterangan2 : '')?></textarea>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan 3</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<textarea id="keterangan3" style="width: 296px; border: 1px solid silver; padding: 1px;" name="keterangan3"><?=($editstatus == 'edit' ? $datarecord->keterangan3 : '')?></textarea>
						</td>
					</tr>
				</table>
			</fieldset>

			<fieldset>
				<legend>Penjualan Paket A</legend>
				<table width="70%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="100">Kode Barang&nbsp;</th>
							<th width="200">Nama Barang&nbsp;</th>
							<th width="100" nowrap>Harga Jual&nbsp;</th>
							<th width="50">Qty&nbsp;</th>
							<th width="80">Satuan Barang&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body_paket">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 100;
							foreach($paket as $pkt) : ?>
								<tr id="paket_<?=$nb?>">
									<td>
										<input type='text' 
											id='kode_barang_paket_<?=$nb?>' 
											name='kode_barang_paket[]' 
											value="<?=$pkt['kode_barang_paket']?>"
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='nama_barang_paket_<?=$nb?>' 
											name='nama_barang_paket[]'
											value="<?=$pkt['nama_barang_paket']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
									</td>
									<td>
										<input type='text' 
											id='harga_jual_<?=$nb?>' 
											name='harga_jual[]' 
											class="getCurrency"
											onchange="currencyFormat(this);" 
											value="<?=$pkt['harga_jual']?>"
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='quantity_<?=$nb?>' 
											name='quantity[]' 
											value="<?=$pkt['quantity']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<select id='satuan_barang_1' name='satuan_barang[]' style="width: 100%; border: none; padding: 1px; background: transparent; ">
											<?=$pkt['optsatuan']?>
										</select>
									</td>
									<td align="center" width="50px;">
										<a href="#" style="text-decoration: none;" onclick="addRows('paket');">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
										</a>
										<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeRows('paket','<?=$nb?>','<?=$pkt['id']?>');" title="Hapus">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
										</a>
										<input type='hidden' name='id_detil[]' value="<?=$pkt['id']?>" >
										<input type='hidden' name='sts_detil[]' value="add" >
									</td>
								</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr id="paket_1" >
							<td>
								<input type='text' 
									id='kode_barang_paket_1' 
									name='kode_barang_paket[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='nama_barang_paket_1' 
									name='nama_barang_paket[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='harga_jual_1' 
									name='harga_jual[]' 
									class="getCurrency"
									onchange="currencyFormat(this);" 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='quantity_1' 
									name='quantity[]' 
									value="" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<select id='satuan_barang_1' name='satuan_barang[]' style="width: 100%; border: none; padding: 1px; background: transparent; ">
									<?=$optsatuan?>
								</select>
							</td>
							
							<td align="center" width="50px;">
								<a href="#" onclick="addRows('paket');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil[]' value="" >
								<input type='hidden' name='sts_detil[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "proses_bbn_unit"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
				<legend>Data Barang</legend>
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<input type='hidden' name='jenis_promosi' value="<?=($editstatus == 'edit' ? $datarecord->jenis_promosi : 'pr_sparepart')?>" >
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Kategori Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='nama_kategori_barang' name='nama_kategori_barang' value="<?=($editstatus == 'edit' ? $datarecord->no_memo : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='nama_barang' name='nama_barang' value="<?=($editstatus == 'edit' ? $datarecord->no_memo : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>

				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Mulai Tanggal</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_mulai' class="datebox" name='tgl_mulai' value="<?=($editstatus == 'edit' ? $datarecord->tgl_mulai : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Berakhir Tanggal</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_berakhir' class="datebox" name='tgl_berakhir' value="<?=($editstatus == 'edit' ? $datarecord->tgl_berakhir : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "proses_pembiayaan_unit"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
				<legend>Proses Pembiayaan</legend>
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Proses Pembiayaan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_proses_pembiayaan' class="datebox" name='tgl_proses_pembiayaan' value="<?=($editstatus == 'edit' ? $datarecord->tgl_proses_pembiayaan : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Supplier</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id="id_group_supplier" name="id_group_supplier" style="width:296px; border: 1px solid silver; padding: 2px;">
								<?=$optgroupsupplier?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Supplier</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id="id_supplier" name="id_supplier" style="width:296px; border: 1px solid silver; padding: 2px;">
								<option>-- Pilih --</option>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Jenis Support</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id="id_jenis_support" name="id_jenis_support" style="width:296px; border: 1px solid silver; padding: 2px;">
								<?=$optjenissupport?>
							</select>
						</td>
					</tr>
				</table>

				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;margin-left:30px;width:450px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No.  Memo</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='no_memo_proses_pembiayaan' name='no_memo_proses_pembiayaan' value="<?=($editstatus == 'edit' ? $datarecord->no_memo_proses_pembiayaan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan Memo</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<textarea id="keterangan" style="width: 296px; border: 1px solid silver; padding: 1px;" name="keterangan"><?=($editstatus == 'edit' ? $datarecord->keterangan : '')?></textarea>
						</td>
					</tr>
				</table>
			</fieldset>
			<fieldset class="support_subsidi" style="display: none;">
				<legend>Subsidi Regular</legend>
				<table width="" border="0" id="table-2">
					<thead>
						<tr>
							<th width="200">Nama Barang&nbsp;</th>
							<th width="150">Mulai Berlaku&nbsp;</th>
							<th width="150">Berakhir Tanggal&nbsp;</th>
							<th width="150">Nilai Subsidi&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body_support_subsidi">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 100;
							foreach($subsidi as $sub) : ?>
								<tr id="support_subsidi_<?=$nb?>" >
									<td>
										<input type='text' 
											id='subsidi_nm_brg_<?=$nb?>' 
											name='subsidi_nm_brg[]'
											value="<?=$sub['nama_barang']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
									</td>
									<td>
										<input type='text' 
											id='subsidi_tgl_mulai_<?=$nb?>' 
											name='subsidi_tgl_mulai[]' 
											class="datebox"
											value="<?=$sub['tgl_mulai_berlaku']?>"
											style="width: 150px; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='subsidi_tgl_akhir_<?=$nb?>' 
											name='subsidi_tgl_akhir[]' 
											class="datebox"
											value="<?=$sub['tgl_akhir_berlaku']?>"
											style="width: 150px; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='subsidi_nilai_<?=$nb?>' 
											name='subsidi_nilai[]' 
											value="<?=$sub['nilai']?>" 
											class="getCurrency" onchange="currencyFormat(this);"
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>

									<td align="center" width="50px;">
										<a href="#" style="text-decoration: none;" onclick="addRows('support_subsidi');">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
										</a>
										<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeRows('support_subsidi','<?=$nb?>', '<?=$sub['id']?>');" title="Hapus">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
										</a>
										<input type='hidden' name='id_detil[]' value="<?=$sub['id']?>" >
										<input type='hidden' name='sts_detil[]' value="add" >
									</td>
								</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr id="support_subsidi_1" >
							<td>
								<input type='text' 
									id='subsidi_nm_brg_1' 
									name='subsidi_nm_brg[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='subsidi_tgl_mulai_1' 
									name='subsidi_tgl_mulai[]' 
									class="datebox"
									style="width: 150px; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='subsidi_tgl_akhir_1' 
									name='subsidi_tgl_akhir[]' 
									class="datebox"
									style="width: 150px; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='subsidi_nilai_1' 
									name='subsidi_nilai[]' 
									class="getCurrency" onchange="currencyFormat(this);"
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							
							<td align="center" width="50px;">
								<a href="#" onclick="addRows('support_subsidi');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil[]' value="" >
								<input type='hidden' name='sts_detil[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>
			</fieldset>
			<fieldset class="support_subsidi" style="display: none;">
				<legend>Subsidi Additional</legend>
				<table width="100%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="200">Nama Barang&nbsp;</th>
							<th width="100">Mulai Berlaku&nbsp;</th>
							<th width="100">Berakhir Tanggal&nbsp;</th>
							<th width="100">Minimal Uang Muka&nbsp;</th>
							<th width="30">Tenor&nbsp;</th>
							<th width="100">Nilai SUbsidi&nbsp;</th>
							<th width="30">Tenor&nbsp;</th>
							<th width="100">Nilai SUbsidi&nbsp;</th>
							<th width="30">Tenor&nbsp;</th>
							<th width="100">Nilai SUbsidi&nbsp;</th>
							<th width="30">Tenor&nbsp;</th>
							<th width="150">Nilai SUbsidi&nbsp;</th>
							<th width="30">Tenor&nbsp;</th>
							<th width="100">Nilai SUbsidi&nbsp;</th>
							<th align="center" >.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body_support_sub_add">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 100;
							foreach($subsidi_add as $add) : ?>
								<tr id="support_sub_add_<?=$nb?>" >
									<td>
										<input type='text' 
											id='sub_add_nm_brg_<?=$nb?>' 
											name='sub_add_nm_brg[]'
											value="<?=$add['nama_barang']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_tgl_mulai_<?=$nb?>' 
											name='sub_add_tgl_mulai[]' 
											class="datebox"
											value="<?=$add['tgl_mulai_berlaku']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_tgl_akhir_<?=$nb?>' 
											name='sub_add_tgl_akhir[]' 
											class="datebox"
											value="<?=$add['tgl_berakhir']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_min_uang_muka_<?=$nb?>' 
											name='sub_add_min_uang_muka[]' 
											value="<?=$add['min_uang_muka']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_tenor_a_<?=$nb?>' 
											name='sub_add_tenor_a[]' 
											value="<?=$add['tenor_a']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_nilai_a_<?=$nb?>' 
											name='sub_add_nilai_a[]' 
											class="getCurrency" onchange="currencyFormat(this);"
											value="<?=$add['nilai_subsidi_a']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_tenor_b_<?=$nb?>' 
											name='sub_add_tenor_b[]' 
											value="<?=$add['tenor_b']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_nilai_b_<?=$nb?>' 
											name='sub_add_nilai_b[]'
											class="getCurrency" onchange="currencyFormat(this);" 
											value="<?=$add['nilai_subsidi_b']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_tenor_c_<?=$nb?>' 
											name='sub_add_tenor_c[]' 
											value="<?=$add['tenor_c']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_nilai_c_<?=$nb?>' 
											name='sub_add_nilai_c[]'
											class="getCurrency" onchange="currencyFormat(this);"
											value="<?=$add['nilai_subsidi_c']?>"  
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_tenor_d_<?=$nb?>' 
											name='sub_add_tenor_d[]' 
											value="<?=$add['tenor_d']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_nilai_d_<?=$nb?>' 
											name='sub_add_nilai_d[]'
											class="getCurrency" onchange="currencyFormat(this);"
											value="<?=$add['nilai_subsidi_d']?>"   
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_tenor_e_<?=$nb?>' 
											name='sub_add_tenor_e[]'  
											value="<?=$add['tenor_e']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>
									<td>
										<input type='text' 
											id='sub_add_nilai_e_<?=$nb?>' 
											name='sub_add_nilai_e[]'
											class="getCurrency" onchange="currencyFormat(this);"  
											value="<?=$add['nilai_subsidi_e']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>

									<td align="center" width="50px;">
										<a href="#" style="text-decoration: none;" onclick="addRows('support_sub_add');">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
										</a>
										<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeRows('support_sub_add','<?=$nb?>', '<?=$add['id']?>');" title="Hapus">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
										</a>
										<input type='hidden' name='id_detil2[]' value="<?=$add['id']?>" >
										<input type='hidden' name='sts_detil2[]' value="add" >
									</td>
								</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr id="support_sub_add_1" >
							<td>
								<input type='text' 
									id='sub_add_nm_brg_1' 
									name='sub_add_nm_brg[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_tgl_mulai_1' 
									name='sub_add_tgl_mulai[]' 
									class="datebox"
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_tgl_akhir_1' 
									name='sub_add_tgl_akhir[]' 
									class="datebox"
									style="width: 100%; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_min_uang_muka_1' 
									name='sub_add_min_uang_muka[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_tenor_a_1' 
									name='sub_add_tenor_a[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_nilai_a_1' 
									name='sub_add_nilai_a[]'
									class="getCurrency" onchange="currencyFormat(this);" 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_tenor_b_1' 
									name='sub_add_tenor_b[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_nilai_b_1' 
									name='sub_add_nilai_b[]' 
									class="getCurrency" onchange="currencyFormat(this);"
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_tenor_c_1' 
									name='sub_add_tenor_c[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_nilai_c_1' 
									name='sub_add_nilai_c[]' 
									class="getCurrency" onchange="currencyFormat(this);"
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_tenor_d_1' 
									name='sub_add_tenor_d[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_nilai_d_1' 
									name='sub_add_nilai_d[]'  
									class="getCurrency" onchange="currencyFormat(this);"
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_tenor_e_1' 
									name='sub_add_tenor_e[]'  
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='sub_add_nilai_e_1' 
									name='sub_add_nilai_e[]'  
									class="getCurrency" onchange="currencyFormat(this);"
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							
							<td align="center" width="50px;">
								<a href="#" onclick="addRows('support_sub_add');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil2[]' value="" >
								<input type='hidden' name='sts_detil2[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>
			</fieldset>
			<fieldset class="support_incentive" style="display: none;">
				<legend>Incentive</legend>
				<table width="%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="200">Nama Barang&nbsp;</th>
							<th width="150">Mulai Berlaku&nbsp;</th>
							<th width="150">Berakhir Tanggal&nbsp;</th>
							<th width="150">Nilai Incentive&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body_support_incentive">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 100;
							foreach($incentive as $inc) : ?>
								<tr id="support_incentive_<?=$nb?>" >
									<td>
										<input type='text' 
											id='incentive_nm_brg_<?=$nb?>' 
											name='incentive_nm_brg[]' 
											value="<?=$inc['nama_barang']?>"
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
									</td>
									<td>
										<input type='text' 
											id='incentive_tgl_mulai_<?=$nb?>' 
											name='incentive_tgl_mulai[]' 
											class="datebox"
											value="<?=$inc['tgl_mulai_berlaku']?>"
											style="width: 150px; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='incentive_tgl_akhir_<?=$nb?>' 
											name='incentive_tgl_akhir[]' 
											class="datebox"
											value="<?=$inc['tgl_akhir_berlaku']?>"
											style="width: 150px; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='incentive_nilai_<?=$nb?>' 
											name='incentive_nilai[]'
											class="getCurrency" onchange="currencyFormat(this);"
											value="<?=$inc['nilai']?>"
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>

									<td align="center" width="50px;">
										<a href="#" style="text-decoration: none;" onclick="addRows('support_incentive');">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
										</a>
										<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeRows('support_incentive','<?=$nb?>', '<?=$inc['id']?>');" title="Hapus">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
										</a>
										<input type='hidden' name='id_detil3[]' value="<?=$inc['id']?>" >
										<input type='hidden' name='sts_detil3[]' value="add" >
									</td>
								</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr id="support_incentive_1" >
							<td>
								<input type='text' 
									id='incentive_nm_brg_1' 
									name='incentive_nm_brg[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='incentive_tgl_mulai_1' 
									name='incentive_tgl_mulai[]' 
									class="datebox"
									style="width: 150px; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='incentive_tgl_akhir_1' 
									name='incentive_tgl_akhir[]' 
									class="datebox"
									style="width: 150px; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='incentive_nilai_1' 
									name='incentive_nilai[]'
									class="getCurrency" onchange="currencyFormat(this);"
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							
							<td align="center" width="50px;">
								<a href="#" onclick="addRows('support_incentive');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil3[]' value="" >
								<input type='hidden' name='sts_detil3[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>
			</fieldset>
			<fieldset class="support_promo" style="display: none;">
				<legend>Program Promo</legend>
				<table width="%" border="0" id="table-2">
					<thead>
						<tr>
							<th width="200">Nama Barang&nbsp;</th>
							<th width="150">Mulai Berlaku&nbsp;</th>
							<th width="150">Berakhir Tanggal&nbsp;</th>
							<th width="150">Nilai Support&nbsp;</th>
							<th align="center">.::.</th>
						</tr>
					</thead>
					<tbody class="tab_body_support_promo">
						<?php if($editstatus=='edit') : ?>
							<?php $nb = 100;
							foreach($promo as $pro) : ?>
								<tr id="support_promo_<?=$nb?>" >
									<td>
										<input type='text' 
											id='promo_nm_brg_<?=$nb?>' 
											name='promo_nm_brg[]' 
											value="<?=$pro['nama_barang']?>"
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
									</td>
									<td>
										<input type='text' 
											id='promo_tgl_mulai_<?=$nb?>' 
											name='promo_tgl_mulai[]' 
											class="datebox"
											value="<?=$pro['tgl_mulai_berlaku']?>"
											style="width: 150px; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='promo_tgl_akhir_<?=$nb?>' 
											name='promo_tgl_akhir[]' 
											class="datebox"
											value="<?=$pro['tgl_akhir_berlaku']?>"			
											style="width: 150px; border: 0; padding: 1px; background: none!important;" />
									</td>
									<td>
										<input type='text' 
											id='promo_nilai_<?=$nb?>' 
											name='promo_nilai[]' 
											class="getCurrency" onchange="currencyFormat(this);"
											value="<?=$pro['nilai']?>" 
											style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
									</td>

									<td align="center" width="50px;">
										<a href="#" style="text-decoration: none;" onclick="addRows('support_promo');">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
										</a>
										<a href="#" class="hapus_row" style="text-decoration: none;" onclick="removeRows('support_promo','<?=$nb?>', '<?=$pro['id']?>');" title="Hapus">
											<img src="<?=base_url()?>assets/css/themes_easyui/icons/delete.png" />
										</a>
										<input type='hidden' name='id_detil4[]' value="<?=$pro['id']?>" >
										<input type='hidden' name='sts_detil4[]' value="add" >
									</td>
								</tr>
							<?php $nb++; endforeach; ?>
						<?php endif ?>
						<tr id="support_promo_1" >
							<td>
								<input type='text' 
									id='promo_nm_brg_1' 
									name='promo_nm_brg[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='promo_tgl_mulai_1' 
									name='promo_tgl_mulai[]' 
									class="datebox"
									style="width: 150px; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='promo_tgl_akhir_1' 
									name='promo_tgl_akhir[]' 
									class="datebox"
									style="width: 150px; border: 0; padding: 1px; background: none!important;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nilai_1' 
									name='promo_nilai[]' 
									class="getCurrency" onchange="currencyFormat(this);"
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							
							<td align="center" width="50px;">
								<a href="#" onclick="addRows('support_promo');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil4[]' value="" >
								<input type='hidden' name='sts_detil4[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "proses_service_ksg"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
					<!-- <legend>Daftar Akun</legend> -->
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kategori Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kategori_barang' name='kategori_barang' value="<?=($editstatus == 'edit' ? $datarecord->kode_akun : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='nama_barang' name='nama_barang' value="<?=($editstatus == 'edit' ? $datarecord->kode_akun : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Supplier</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='nama_supplier' name='nama_supplier' value="<?=($editstatus == 'edit' ? $datarecord->kode_akun : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Alamat</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='alamat' name='alamat' value="<?=($editstatus == 'edit' ? $datarecord->kode_akun : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
			</fieldset>
			<fieldset style="overflow: auto;">
				<legend>Data Service Kartu</legend>
				<table border="0" width="170%"  id="table-2">
					<thead>
						<tr>
							<th width="200" rowspan="2">Group Service&nbsp;</th>
							<th width="200" rowspan="2">Kategori Service&nbsp;</th>
							<th width="150" rowspan="2">Harga Kartu KSG&nbsp;</th>
							<th width="150" rowspan="2">Jarak Tempuh&nbsp;</th>
							<th width="150" rowspan="2">Dari Jangka Waktu Beli&nbsp;</th>
							<th width="150" colspan="4">Oli Yamalube&nbsp;</th>
							<th width="150" colspan="4">Oli Yamalube Matic&nbsp;</th>
							<th width="150" colspan="4">Oli Gear Yamalube&nbsp;</th>
							<th width="150" colspan="4">Yamalube Coolant&nbsp;</th>
							<th width="100" align="center" rowspan="2">.::.</th>
						</tr>
						<tr>
							<th width="150">Kode Barang&nbsp;</th>
							<th width="150">Nama Barang&nbsp;</th>
							<th width="150">Qty&nbsp;</th>
							<th width="150">Satuan&nbsp;</th>
							<th width="150">Kode Barang&nbsp;</th>
							<th width="150">Nama Barang&nbsp;</th>
							<th width="150">Qty&nbsp;</th>
							<th width="150">Satuan&nbsp;</th>
							<th width="150">Kode Barang&nbsp;</th>
							<th width="150">Nama Barang&nbsp;</th>
							<th width="150">Qty&nbsp;</th>
							<th width="150">Satuan&nbsp;</th>
							<th width="150">Kode Barang&nbsp;</th>
							<th width="150">Nama Barang&nbsp;</th>
							<th width="150">Qty&nbsp;</th>
							<th width="150">Satuan&nbsp;</th>
						</tr>
					</thead>
					<tbody class="tab_body_proses_ksg">
						<tr id="proses_ksg_1" >
							<td>
								<select id='id_group_service_1' name='id_group_service[]' style="width: 100%; border: none; padding: 1px; background: transparent; ">
									<option>--Pilih--</option>
								</select>
							</td>
							<td>
								<select id='kategori_service_1' name='kategori_service[]' style="width: 100%; border: none; padding: 1px; background: transparent; ">
									<option>--Pilih--</option>
								</select>
							</td>
							<td>
								<input type='text' 
									id='promo_nm_brg_1' 
									name='promo_nm_brg[]' 
									class="getCurrency" onchange="currencyFormat(this);"
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nilai_1' 
									name='promo_nilai[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nm_brg_1' 
									name='promo_nm_brg[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nilai_1' 
									name='promo_nilai[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nm_brg_1' 
									name='promo_nm_brg[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nilai_1' 
									name='promo_nilai[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td width="150">
								<select id='satuan_barang_1' name='satuan_barang[]' style="width: 100%; border: none; padding: 1px; background: transparent; ">
									<option>--Pilih--</option>
								</select>
							</td>
							<td>
								<input type='text' 
									id='promo_nilai_1' 
									name='promo_nilai[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nm_brg_1' 
									name='promo_nm_brg[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nilai_1' 
									name='promo_nilai[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<select id='satuan_barang_1' name='satuan_barang[]' style="width: 100%; border: none; padding: 1px; background: transparent; ">
									<option>--Pilih--</option>
								</select>
							</td>
							<td>
								<input type='text' 
									id='promo_nilai_1' 
									name='promo_nilai[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nm_brg_1' 
									name='promo_nm_brg[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nilai_1' 
									name='promo_nilai[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<select id='satuan_barang_1' name='satuan_barang[]' style="width: 100%; border: none; padding: 1px; background: transparent; ">
									<option>--Pilih--</option>
								</select>
							</td>
							<td>
								<input type='text' 
									id='promo_nilai_1' 
									name='promo_nilai[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nm_brg_1' 
									name='promo_nm_brg[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent;" />
							</td>
							<td>
								<input type='text' 
									id='promo_nilai_1' 
									name='promo_nilai[]' 
									style="width: 100%; border: 0; padding: 1px; background: none!important; background: transparent; text-align: right;" />
							</td>
							<td>
								<select id='satuan_barang_1' name='satuan_barang[]' style="width: 100%; border: none; padding: 1px; background: transparent; ">
									<option>--Pilih--</option>
								</select>
							</td>
							<td align="center" width="50px;">
								<a href="#" onclick="addRows('support_promo');">
									<img src="<?=base_url()?>assets/css/themes_easyui/icons/add.png" title="Tambah" />
								</a>
								<input type='hidden' name='id_detil4[]' value="" >
								<input type='hidden' name='sts_detil4[]' value="add" >
							</td>
						</tr>
					</tbody>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "kode_akun"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
				<!-- <legend>Daftar Akun</legend> -->
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:470px;">
					
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Type Akun</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='type_akun' name='type_akun' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optakuntype?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">No. Akun</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun' name='kode_akun' value="<?=($editstatus == 'edit' ? $datarecord->kode_akun : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Akun</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='nama_akun' name='nama_akun' value="<?=($editstatus == 'edit' ? $datarecord->nama_akun : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Bagian Dari Akun</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='bagian_dari_akun' name='bagian_dari_akun' value="<?=($editstatus == 'edit' ? $datarecord->bagian_dari_akun : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Status System</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='status' name='status' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optstatus?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='keterangan' name='keterangan' value="<?=($editstatus == 'edit' ? $datarecord->keterangan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tanggal_akun' class="datebox" name='tanggal_akun' value="<?=($editstatus == 'edit' ? $datarecord->tanggal_akun : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Saldo Awal</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='saldo_awal' name='saldo_awal' value="<?=($editstatus == 'edit' ? $datarecord->saldo_awal : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "akun_kas"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
				<!-- <legend>Daftar Akun</legend> -->
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<table cellpadding="0" cellspacing="2" style="float:left;padding-top:0px;width:770px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Group Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_group_dealer' name='id_group_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optgroupdealer?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_dealer' name='id_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
								<option value=''>-- Pilih --</option>
							</select>
						</td>
					</tr>
					<!-- <tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Kas</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='type_akun' name='type_akun' style="width:300px; border: 1px solid silver; padding: 1px;">
							</select>
						</td>
					</tr> -->
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Kas</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_kas' name='id_kas' style="width:300px; border: 1px solid silver; padding: 1px;">
								<option value=''>-- Pilih --</option>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Type Akun</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='type_akun' name='type_akun' style="width:187px; border: 1px solid silver; padding: 1px; float: left; margin-right: 5px;">
								<?=$optakuntype?>
							</select>
							<input type='text' id='kode_akun_kas' disabled="disabled" name='kode_akun_kas' value="<?=($editstatus == 'edit' ? $datarecord->type_akun : '')?>" style="width:100px; border: 1px solid silver; padding: 2px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Bagian Dari Akun</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='bagian_dari_akun' name='bagian_dari_akun' style="width:187px; border: 1px solid silver; padding: 1px; float: left; margin-right: 5px;">
								<?=$optbagianakun?>
							</select>
							<input type='text' id='kode_bagian_akun' disabled="disabled" name='kode_bagian_akun' value="<?=($editstatus == 'edit' ? $datarecord->bagian_dari_akun : '')?>" style="width:100px; border: 1px solid silver; padding: 2px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Bagian Dari Sub akun</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='bagian_dari_sub_akun' name='bagian_dari_sub_akun' style="width:187px; border: 1px solid silver; padding: 1px; float: left; margin-right: 5px;">
								<?=$optsubakun?>
							</select>
							<input type='text' id='kode_sub_akun' disabled="disabled" name='kode_sub_akun' value="<?=($editstatus == 'edit' ? $datarecord->bagian_dari_sub_akun : '')?>" style="width:100px; border: 1px solid silver; padding: 2px;">
						</td>
					</tr>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "akun_barang_jasa"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
				<!-- <legend>Daftar Akun</legend> -->
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<table cellpadding="0" cellspacing="2" style="padding-top:0px;width:770px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Group Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_group_barang' name='id_group_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optgroupbarang?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Kategori Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_kategori_barang' name='id_kategori_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optkategoribarang?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tipe Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='radio' name='id_tipe_barang' <?=$persediaan?> value='1'>&nbsp; Persediaan &nbsp;&nbsp;
							<input type='radio' name='id_tipe_barang' <?=$nonpersediaan?> value='2'>&nbsp; Non Persediaan &nbsp;&nbsp;
							<input type='radio' name='id_tipe_barang' <?=$jasa?> value='3'>&nbsp; Jasa
						</td>
					</tr>
				</table>
			</fieldset>
			<fieldset>
				<table>
					<tr>
						<th style="text-align: center;">NAMA AKUN</th>
						<th style="text-align: center;">KODE AKUN</th>
						<th style="text-align: center;">NAMA AKUN</th>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun Persediaan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_persediaan' disabled="disabled" name='kode_akun_persediaan' style="width:150px; border: 1px solid silver; padding: 2px;">	
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_persediaan' name='kd_akun_persediaan' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optakunpersediaan?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun Penjualan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_jual' disabled="disabled" name='kode_akun_jual' style="width:150px; border: 1px solid silver; padding: 2px;">
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_jual' name='kd_akun_jual' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optakunjual?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun Retur Penjualan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_retur_jual' disabled="disabled" name='kode_akun_retur_jual' style="width:150px; border: 1px solid silver; padding: 2px;">
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_retur_jual' name='kd_akun_retur_jual' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optakunreturjual?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun Discount Penjualan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_diskon_jual' disabled="disabled" name='kode_akun_diskon_jual' style="width:150px; border: 1px solid silver; padding: 2px;">
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_diskon_jual' name='kd_akun_diskon_jual' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optakundiskonjual?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun Barang Terkirim</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_brg_terkirim' disabled="disabled" name='kode_akun_brg_terkirim' style="width:150px; border: 1px solid silver; padding: 2px;">
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_brg_terkirim' name='kd_akun_brg_terkirim' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optakunbarangkirim?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun HPP</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_hpp' disabled="disabled" name='kode_akun_hpp' style="width:150px; border: 1px solid silver; padding: 2px;">
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_hpp' name='kd_akun_hpp' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optakunhpp?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun Retur Pembelian</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_retur_beli' disabled="disabled" name='kode_akun_retur_beli' style="width:150px; border: 1px solid silver; padding: 2px;">
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_retur_beli' name='kd_akun_retur_beli' style="width:187px; border: 1px solid silver; padding: 1px; float: left; margin-right: 5px;">
								<?=$optakunreturbeli?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun Belum Tertagih</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_belum_tertagih' disabled="disabled" name='kode_akun_belum_tertagih' style="width:150px; border: 1px solid silver; padding: 2px;">
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_belum_tertagih' name='kd_akun_belum_tertagih' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optakunbelumtertagih?>
							</select>
						</td>
					</tr>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "akun_aktifa_tetap"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
				<!-- <legend>Daftar Akun</legend> -->
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<table cellpadding="0" cellspacing="2" style="padding-top:0px;width:770px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Group Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_group_dealer' name='id_group_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$optgroupdealer?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_dealer' name='id_dealer' style="width:300px; border: 1px solid silver; padding: 1px;">
								<option value=''>-- Pilih --</option>
							</select>
						</td>
					</tr>
				</table>
			</fieldset>
			<fieldset>
				<legend>Identitas Aktifa Tetap</legend>
				<table>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:500px">
							<input type='text' id='nama_barang' name='nama_barang' value="<?=($editstatus == 'edit' ? $datarecord->nama_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
							<a id="get_nama_barang_<?=$type?>" class="l-btn l-btn-plain" href="#"> &nbsp;
								<span class="l-btn-left">
									<span class="l-btn-text icon-search" style="padding-left: 20px;">&nbsp;</span>
								</span>
							</a>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Quantity</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='quantity' name='quantity' value="<?=($editstatus == 'edit' ? $datarecord->quantity : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Satuan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='satuan' name='satuan' value="<?=($editstatus == 'edit' ? $datarecord->satuan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Harga Satuan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='hrg_satuan' name='hrg_satuan' value="<?=($editstatus == 'edit' ? $datarecord->hrg_satuan : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Total Harga</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='total_harga' name='total_harga' value="<?=($editstatus == 'edit' ? $datarecord->total_harga : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Pembelian</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_beli' name='tgl_beli' class="datebox" value="<?=($editstatus == 'edit' ? $datarecord->tgl_beli : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Tanggal Penggunaan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='tgl_penggunaan' name='tgl_penggunaan' class="datebox" value="<?=($editstatus == 'edit' ? $datarecord->tgl_penggunaan : date('Y-m-d'))?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Posisi Di Departemen</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='posisi_departemen' name='posisi_departemen' value="<?=($editstatus == 'edit' ? $datarecord->posisi_departemen : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Keterangan Detail Barang</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='ketdet_barang' name='ketdet_barang' value="<?=($editstatus == 'edit' ? $datarecord->ketdet_barang : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kode Aktiva</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kd_aktiva' name='kd_aktiva' value="<?=($editstatus == 'edit' ? $datarecord->kd_aktiva : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Type Aktiva</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='type_aktiva' name='type_aktiva' style="width:300px; border: 1px solid silver; padding: 1px;">
								<?=$opttypeaktiva?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Metode Penyusutan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='metode_susut' name='metode_susut' value="<?=($editstatus == 'edit' ? $datarecord->metode_susut : '')?>" style="width:296px; border: 1px solid silver; padding: 1px;">
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Umur Aktiva</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='umur_aktiva_thn' name='umur_aktiva_thn' value="<?=($editstatus == 'edit' ? $datarecord->umur_aktiva_thn : '')?>" style="width:36px; border: 1px solid silver; padding: 1px;"> Tahun
							<input type='text' id='umur_aktiva_bln' name='umur_aktiva_bln' value="<?=($editstatus == 'edit' ? $datarecord->umur_aktiva_thn : '')?>" style="width:36px; border: 1px solid silver; padding: 1px;"> Bulan
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Kategori Barang Aktiva</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							
						</td>
					</tr>
				</table>
			</fieldset>
			<fieldset>
				<table>
					<tr>
						<th style="text-align: center;">NAMA AKUN</th>
						<th style="text-align: center;">KODE AKUN</th>
						<th style="text-align: center;">NAMA AKUN</th>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun Aktiva</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_aktiva' disabled="disabled" name='kode_akun_aktiva' value="<?=($editstatus == 'edit' ? $datarecord->kd_akun_aktiva : '')?>" style="width:150px; border: 1px solid silver; padding: 2px;">	
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_aktiva' name='kd_akun_aktiva' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optakunaktiva?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun Akum Penyusutan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_akum_susut' disabled="disabled" name='kode_akun_akum_susut' value="<?=($editstatus == 'edit' ? $datarecord->kd_akun_akum_susut : '')?>" style="width:150px; border: 1px solid silver; padding: 2px;">
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_akum_susut' name='kd_akun_akum_susut' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optakunpenyusutan?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Akun Bebat Penyusutan</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_akun_bebat_susut' disabled="disabled" name='kode_akun_bebat_susut' value="<?=($editstatus == 'edit' ? $datarecord->kd_akun_bebat_susut : '')?>" style="width:150px; border: 1px solid silver; padding: 2px;">
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='kd_akun_bebat_susut' name='kd_akun_bebat_susut' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optbebatpenyusutan?>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Open Balance Equity</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<input type='text' id='kode_open_balance_qty' disabled="disabled" name='kode_open_balance_qty' value="<?=($editstatus == 'edit' ? $datarecord->open_balance_qty : '')?>" style="width:150px; border: 1px solid silver; padding: 2px;">
						</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='open_balance_qty' name='open_balance_qty' style="width:187px; border: 1px solid silver; padding: 1px;">
								<?=$optopenbalanceqty?>
							</select>
						</td>
					</tr>
				</table>
			</fieldset>
		</form>
	<?php }elseif($type == "akun_saldo"){ ?>
		<form method="post" id="<?=$type?>_form" url="<?=base_url()?>master/savedata/<?=$type?>" enctype="multipart/form-data">
			<fieldset>
				<!-- <legend>Daftar Akun</legend> -->
				<input type='hidden' name='editstatus' value="<?=$editstatus?>" >
				<input type='hidden' name='id' value="<?=($editstatus == 'edit' ? $datarecord->id : '')?>" >
				<table cellpadding="0" cellspacing="2" style="padding-top:0px;width:770px;">
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Group Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_group_barang' name='id_group_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
								<option value=''>-- Pilih --</option>
							</select>
						</td>
					</tr>
					<tr>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:35%;">Nama Dealer</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:10px">:</td>
						<td style="vertical-align: top; font-family: inherit; padding-bottom: 5px; width:100px">
							<select id='id_kategori_barang' name='id_kategori_barang' style="width:300px; border: 1px solid silver; padding: 1px;">
								<option value=''>-- Pilih --</option>
							</select>
						</td>
					</tr>
				</table>
			</fieldset>
		</form>
	</div>
<?php } ?>
	<div region="south" border="false" style="text-align:right;padding:5px 0;">
		<a id="btnSend_<?=$type?>" class="l-btn l-btn-plain" iconcls="disk" href="#">
            <span class="l-btn-left">
                <span class="l-btn-text disk" style="padding-left: 20px;">Simpan</span>
            </span>
        </a>
		<a id="btnBatal_<?=$type?>" class="l-btn l-btn-plain" onclick="kembali('<?=$type?>')" iconcls="cancel" href="#">
            <span class="l-btn-left">
                <span class="l-btn-text cancel" style="padding-left: 20px;">Batal</span>
            </span>
        </a>
	</div>
</div>

<script>
	var type = "<?=$type?>";
	var editstatus = "<?=$editstatus?>";
	
	<?php if($type == 'motor' || $type == 'generator' || $type == 'sparepart' || $type == 'peralatan_service' || $type == 'barang_promosi'){?>
		var kategoribarang = "<?=($editstatus == 'edit' ? $datarecord->id_kategori_barang : '')?>";
		var kondisippnjual = "<?=$optkondisippnjual?>";
		var tingkathrgjual = "<?=$opttingkathrgjual?>";
	<?php } ?>
	
	<?php if($type == 'karyawan'){?>
		var tglmulaikerja = "<?=($editstatus == 'edit' ? $datarecord->tanggal_masuk_kerja : '')?>";
	<?php } ?>
	
	<?php if($type == 'proses_promosi_unit' || $type == 'proses_promosi_sparepart' || $type == 'proses_promosi_service') { ?>
		<?php if ($type == 'proses_promosi_unit') { ?>
			var promodealer = "<?=$optdealerpromo?>";
			var promosi_all_dealer = "<?=($editstatus == 'edit' ? $datarecord->promosi_all_dealer : '')?>";
			var jenis_penjualan = "<?=($editstatus == 'edit' ? $datarecord->jenis_penjualan : '')?>";
		<?php } ?>
		<?php if ($type == 'proses_promosi_service') { ?>
			var optgroupbarang = "<?=$optgroupbarang?>";
			var optsatuan = "<?=$optsatuan?>";
			var id_dealer = "<?=($editstatus == 'edit' ? $datarecord->id_dealer : '')?>";
			var kategori_brg = "<?=($editstatus == 'edit' ? $datarecord->id_kategori_barang : '')?>";
			var kategori_service = "<?=($editstatus == 'edit' ? $datarecord->id_kategori_service : '')?>";
		<?php } ?>
		<?php if ($type == 'proses_promosi_sparepart') { ?>
			var optsatuan = "<?=$optsatuan?>";
		<?php } ?>
		
		//var tgl_mulai_promo = "<?=($editstatus == 'edit' ? $datarecord->tgl_mulai : '0')?>";
		//var tgl_berakhir_promo = "<?=($editstatus == 'edit' ? $datarecord->tgl_berakhir : '0')?>";
	<?php } ?>

	<?php if ($type == 'proses_pembiayaan_unit') { ?>
		var id_supplier   = "<?=($editstatus == 'edit' ? $datarecord->id_supplier : '')?>";
		var jenis_support = "<?=($editstatus == 'edit' ? $datarecord->id_jenis_support : '')?>";
	<?php } ?>
	
	<?php if($type == 'service'){?>
		var kategoriservice = "<?=($editstatus == 'edit' ? $datarecord->id_kategori_service : '')?>";
	<?php } ?>
	
	<?php if($type == 'aktiva'){?>
		var tglpembelian = "<?=($editstatus == 'edit' ? $datarecord->tanggal_pembelian : '')?>";
		var tglpemakaian = "<?=($editstatus == 'edit' ? $datarecord->tanggal_pemakaian : '')?>";
	<?php } ?>
	
	<?php if($type == 'akun_kas' || $type == 'akun_aktifa_tetap'){?>
		var id_dealer = "<?=($editstatus == 'edit' ? $datarecord->id_dealer : '')?>";
		<?php if($type == 'akun_kas') { ?> 
			var id_kas = "<?=($editstatus == 'edit' ? $datarecord->id_kas : '')?>"; 
		<?php } ?>
	<?php } ?>
	
	<?php if($type == 'akun_barang_jasa'){ ?>
		var kategoribarang = "<?=($editstatus == 'edit' ? $datarecord->id_group_barang : '')?>";
	<?php } ?>
	//alert(type);
</script>
<script type="text/javascript" src="<?=base_url()?>assets/js/master/master_form.js"></script>
